Page 1 of 1

folder question

Posted: Mon Feb 17, 2014 9:31 pm
by Richard Chidiak
Hello

I wan to dynamically load prompt and dialogs for a folder, using dialog and resources.

The ideal will be something like

REDEFINE FOLDER oFld ID 201 OF oDlg PROMPTS zprmpts DIALOGS zdlgs ADJUST where zprmpts and zdlgs are tables containing the prompts and dialogs.

This does not work and errors at redefine method because of default value to len(aprompts).

Activate dialog on init(OFLD:SETPROMPTS(zprmpts)) does not help neither

Any clue ?

Thanks for help

Richard

Re: folder question

Posted: Mon Feb 17, 2014 9:37 pm
by cnavarro
Richard Chidiak wrote:Hello

I wan to dynamically load prompt and dialogs for a folder, using dialog and resources.

The ideal will be something like

REDEFINE FOLDER oFld ID 201 OF oDlg PROMPTS zprmpts DIALOGS zdlgs ADJUST where zprmpts and zdlgs are tables containing the prompts and dialogs.

This does not work and errors at redefine method because of default value to len(aprompts).

Activate dialog on init(OFLD:SETPROMPTS(zprmpts)) does not help neither

Any clue ?

Thanks for help

Richard
If zprmpts and zdlgs are tables so you will have to appoint zprmpts[x] and zdlgs[x], no?

Re: folder question

Posted: Mon Feb 17, 2014 9:49 pm
by Richard Chidiak
If zprmpts and zdlgs are tables so you will have to appoint zprmpts[x] and zdlgs[x], no?

I want them to be dynamically loaded at run time, so they may be different from one user to another.

Basically i would do ,;

REDEFINE FOLDER oFld ID 201 OF oDlg ;
PROMPTS zprmpts[1],zprmpts[2],zprmpts[3];
DIALOGS zdlgs[1],zdlgs[2],zdlgs[3] ADJUST

this is an example , in real case the table is up to 15 entries

i want this to be

ofld:aprompts := zprmpts
ofld:adialogs := Zdlgs

zprmpts and zdlgs would hold the prompts and dialogs.