How to enable/disable a field based on mainframe behaviour.

I am using ApplinX 8. I need to combine three screens from mainframe into a single screen. I am able to collect and display data from all three screens.

The problem is enabling/disabling of the fields. I can do that by Java Script but few fields will enabled for a particular user and can be disabled for some another user. So I need to enabled/disabled a field based upon the state of the field on the mainframe.

How do I know whether a particular field is enabled or disabled on the mainframe?
Since I am using a path in order to collect the data from different screens, now after I have gone through different screens collecting the data and finally displaying the consolidated data how will I know whether a particular field was enabled/disabled?

Please help and please reply back if any more info is required.

HI Pijus,

Assume there is a screen “ABCD” consists of 10 fields [5 protected, 5 unprotected].
To find out which field is enable(unprotected)/disable(protected) do the following stuff inside “gx_preRender” method of GXBasicContext. Or inside gx_onInit() method of corresponding customized java


GXIFieldCollection coll = getGXSession().getScreen().getFields().getAppFields();

int count = coll.getFieldCount(),i=0;

System.out.println(coll.getFieldAt(i).getName()+" is disable");
}else {
System.out.println(coll.getFieldAt(i).getName()+" is enable");


Arijit :smiley:

Hi Kumar,

You have two options to get the field attribute data.
Since last time we recommended you to use the “execute procedure

Thanks Gadi,
The option “Send To Base Object” is working great. One more thing that I noticed and wanted to share with you was that it not only enable’s or disable’s a field but it also retrieves the fields data and based upon the id it fills the data as well as enables and disables it.

What I wanted to know is what is the difference between retrieving data using “Screen Mapper

Hi Kumar,

The general rule-of-thumb is to use the procedures (“Screen Mapper