Write the below code in Class declaration :
public class FormRun extends ObjectRun
{
#AOT
TreeNode treeMenuItem,treeForm,table;
}
-------------------------------------------------------------------------------------------------------------------
Write the below code in combo box SelectionChange Method :
public int selectionChange()
{
int ret;
ret = super();
if(this.selection()== Account_Type::Customer)
{
treeForm = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test\Fields\AccountNum\");
treeForm.AOTsetProperties("Properties\n ExtendedDataType #" + 'CustAccount' + "\n ENDPROPERTIES\n");
table = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test");
treeForm.AOTSave();
table.AOTsave(); // To save the table
Esh_Test_ds.refresh(); // To refresh the changes made in form data source
}
else if(this.selection()== Account_Type::Vendor)
{
treeForm = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test\Fields\AccountNum\");
treeForm.AOTsetProperties("Properties\n ExtendedDataType #" + 'VendAccount' + "\n ENDPROPERTIES\n");
table = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test");
treeForm.AOTSave();
table.AOTsave(); // To save the table
Esh_Test_ds.refresh(); // To refresh the changes made in form data source
}
return ret;
}
public class FormRun extends ObjectRun
{
#AOT
TreeNode treeMenuItem,treeForm,table;
}
-------------------------------------------------------------------------------------------------------------------
Write the below code in combo box SelectionChange Method :
public int selectionChange()
{
int ret;
ret = super();
if(this.selection()== Account_Type::Customer)
{
treeForm = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test\Fields\AccountNum\");
treeForm.AOTsetProperties("Properties\n ExtendedDataType #" + 'CustAccount' + "\n ENDPROPERTIES\n");
table = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test");
treeForm.AOTSave();
table.AOTsave(); // To save the table
Esh_Test_ds.refresh(); // To refresh the changes made in form data source
}
else if(this.selection()== Account_Type::Vendor)
{
treeForm = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test\Fields\AccountNum\");
treeForm.AOTsetProperties("Properties\n ExtendedDataType #" + 'VendAccount' + "\n ENDPROPERTIES\n");
table = treeNode::findNode(@"\Data Dictionary\Tables\Esh_Test");
treeForm.AOTSave();
table.AOTsave(); // To save the table
Esh_Test_ds.refresh(); // To refresh the changes made in form data source
}
return ret;
}
No comments:
Post a Comment