Hi,

look at the class ReleaseUpdateDB

the method "run", you will find a sample.

Regards,
Olivier Parent ,
Competence Center Axapta
SYLIS Belgium S.A./N.V.
http://www.sylis.be
______________________
Tel 00 32 4 264.00.00
Fax 00 32 4 248.05.38
______________________





"smeagul2303" <[EMAIL PROTECTED]>
29/12/2004 17:19
Please respond to development-axapta


        To:     [email protected]
        cc:
        Subject:        [development-axapta] Dynamic call to a method





Hello,

I want to call methods from an object dynamically.
Let's say I have a container including strings. The strings are
methodnames of an object. Now I want to go through the container and
sending each method to the object.

What is the construction for that ?

With a table and fieldIds it is easy:

Container fieldIds;
CustTable  cust;

fieldIds = conPoke(fieldIds, conLen(fieldIds)+1, fieldNum(cust,
Name));
fieldIds = conPoke(fieldIds, conLen(fieldIds)+1, fieldNum(cust,
Address));
.....

all fieldIds are in the container. To make a call to a custtable I do:

for(i = 1; i <= conLen(fieldIds); i++)
{
  fieldId = conPoke(fieldIds, i);
  info(strfmt("FieldId %1 Value: %2", fieldId, custTable.(fieldId)));
}

So with fieldIds I do the call: table.(fieldId)
but how do I do it with methods ?
object.methodName ?? That is a syntax error.

Regards

Manfred










Yahoo! Groups Links











[Non-text portions of this message have been removed]





Yahoo! Groups Sponsor
ADVERTISEMENT
click here


Yahoo! Groups Links

Reply via email to