how to pass value from form to class

Hi All,

I want to pass control value from form to class.

please anybody can help me.



Hi Stanly,

Its very simple

  1. Take control String in the form design like string Customer Name

  2. Go to control String properties Auto declaration YES

3.Go to form methods → new method → write return type method like

public str customerName()


return CustomerName.Text();


4.Go to class main method write like this

public static void main(Args args)

str custName;

if(formHasMethod(args.caller(), identifierStr(custmerName)))
custName = args.caller().custmerName();



  1. open form enter text into text box call this class through menuitembuttonit will bework

display info log u enter text

6.write like this code each and very control

send your email I will send xpo file

My email id

1 Like

Hi stan

You got best reply from chandra, yes its helps you



Chandra thnx,but I am getting an error that method should be edit or display…

In this scenario,what can be done?

I did it as a display method;but somehow I am unable to edit control due to this…

can u help me to get out of it?