Home › Forum › Omnis General Forum › Droplist inside a grid cell
Tagged: General Coding
-
Droplist inside a grid cell
Posted by Coralie on April 1, 2019 at 11:58 amHi everyone,
I would like to add a droplist inside of an enterable data grid. Is there any way to achieve this?
Thanks in advance.
Coralie.Klaus Schrödl replied 5 years, 3 months ago 3 Members · 5 Replies -
5 Replies
-
Hi Coralie,
I suppose, you’re talking about standard Windows Forms (Fat client), not the jsClient.
There you have (at least) two possibilities:
1. Use a complex grid. Each data column can be represented by almost any control like en try fields, check boxes and of course droplists.
2. Use a datagrid, set the $userdefined property to kTrue, the $columntype of the particular column to
kDataGridDropListPicker and the $columnpicklist property to the list variable containing the values to be displayed in the droplist AND the values corresponding to the list column being displayed/set in this column.
The columns picklist at least has to have two columns:
First column contains a string value being displayed when the user clicks on the droplist.
Second columns contains the values being set in the list behind the datagrid and preferably should have the same data type.
HTH
Cheers
Klaus -
Hi Klaus,
Thank you for the reply. I’m deeply sorry for forgetting to say that I am actually using a Js Remote Form but I’m hoping it doesn’t change much what you (very well as a matter of fact) explained…
Regards,
Coralie. -
We’re looking at this for a jsClient project we’re doing for a client. I’m fairly sure it’s similar to the thick client.
-
Hi everyone,
I did it with the JsClient, just the way Klaus explained, and it works perfectly.
In case someone needs it:
-Change the $userdefined property to kTrue
-Change the $columnType property to kJSDataGridModeDropList
-For each column of the data grid, set the $columndatacol property to the number corresponding to your datalist’s columns.
-Set a variable(list type) to the $columnpicklist property (for instance iDropList)
-Then in the construct of the class method:
Do iDropList.$add(‘Ok’;1)
Do iDropList.$add(‘it’;2)
Do iDropList.$add(‘works’;2)
Thanks again,
Regards,
Coralie
Log in to reply.