Hello, i need help. I have a Codeunit that runs a Form (with Form.RUN function). On this Form i have a text variable to modify. Then when i close the form, i need this value in the Codeunit.
clear(frmMyForm);
IF frmMyForm.RUNMODAL = ACTION::LookupOk THEN BEGIN
MESSAGE('%1',frmMyForm.GetReturnValue());
END;
Of course you have to create a lookup-ok button if you don't have it(copy the Ok button from Form 4) and if you add the cancel-button, you can also cancel the action and you wont see the message.
In the form, you have to create this function:
GetReturnValue() : (return-type is the type of your variable)
BEGIN
EXIT("My Variable");
END;
Regards,Alain Krikilion No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
Comments
frmMyForm Form "My Form"
Of course you have to create a lookup-ok button if you don't have it(copy the Ok button from Form 4) and if you add the cancel-button, you can also cancel the action and you wont see the message.
In the form, you have to create this function:
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
The following code is in case you don't have a table:
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
there is also a how to for it : http://www.mibuso.com/howtoinfo.asp?FileID=7
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
http://www.BiloBeauty.com
http://www.autismspeaks.org