Источник:
http://www.axaptapedia.com/Adding_on...sion_in_Dialog
==============
Summary: New page: To add new field in dialog we use '''addField()''' method. When we try to add for example Dimension field Axapta adds all the fields automatically. But sometimes we need to add only one pa...
<div>To add new field in dialog we use '''addField()''' method. When we try to add for example Dimension field Axapta adds all the fields automatically.
But sometimes we need to add only one particular field.
=== Idea ===
To solve this problem we just need to pass array index as parameter.
=== Solution ===
1. Add into Dialog class '''addField()''' method another one parameter:
DialogField addField(
int type,
FieldLabel label = '',
FieldHelp help = '',
ArrayIdx idx = 0 //GRR modified for ArrayFields
)
{
DialogField DialogField;
fields += 1;
DialogField = new DialogField(this,type,fields);
this.addCtrlDialogField(dialogField.name());
// dialogField.init(this); //standard
dialogField.init(this, idx);//GRR modified for ArrayFields
if (label)
dialogField.label(label);
if (help)
dialogField.helpText(help);
this.addDialogClass(dialogField);
return dialogField;
}
2. Add into DialogField class '''init()''' before while (f
if((idx)&&(idx