Is it possible to move a user defined field (UDF) to the main form/window on a certain position ? If yes, can someone provide an example? For example I do not know how to get the field from the UDF window or how to get a reference of the UDF window.
Asked
Active
Viewed 1,251 times
1 Answers
1
I did not find a way to move a UDF field, but I found a way to clone it:
Form myForm = ...;//get Form
myForm.Freeze(true);//freeze form for the flickering problem
Item itemTmp = myForm.Items.Add("NewItemId", BoFormItemTypes.it_COMBO_BOX);
ComboBox comboItem = itemTmp.Specific;
comboItem.ExpandType = BoExpandType.et_DescriptionOnly;
itemTmp.DisplayDesc = true;//display the description of the selected value
comboItem.DataBind.SetBound(true, "OITM", "U_HGR_id");//OITM is the DB table for Items/Articles. U_HGR_id is the UDF field (also column name) that I want to clone to the main window
loadUdfValuesInCombo(comboItem);//a local function that loads the values in the newly created combobox
myForm.Freeze(false);//unfreeze form

V G
- 18,822
- 6
- 51
- 89