Jump to content

Recommended Posts

Posted

Hi,

I have a DBgrid  with some fields;

for two Columns I fill the PickList property with some values.

 

The 1st pickList is fixed,  while for my application, the values in the second depends on the item selected in the first combo.

 

So I dynamically populate the second list depending on the NEW values selected during edit of the first combo.

 

My problem is that  I am not able to catch this New value; I am still in Edit of the row (still not posted)

and after selection on 1st combo I get always the old value (current in DB).

instead of the New selected...

 

I tried to link to the 1st column a specific DBComboBox component,  which have a 'onCloseUp' event
but I stil gest the "old" value, not the new selection...

 

Any idea on how get the New selected value ?

 

Thank you,

Marco

  • Administrators
Posted

Regular edition

 

Please try to use the latest build.

 

Regarding your question. Do you use a ComboBox as column editor or use the Column.PickList?  Do you want to dynamically change the picklist items?

Posted

ok, installing last ver...
 

I have tried both combo editor and column pickList;

the dynamic change of itemList or pickList seems work fine.

 

my problem is dynamically get the value (item) choosen by user while is editing a record.

Posted

with last ver. 0.99.50.1187

the result is the same; onCloseUp of the DBComboBox (as editor in a column grid) I get the old value instead of ther new selected.

 

Also I dont know if it's better get it from the dataset or from the column field...

 

for dataset I use

   newValue := tabGrants.FieldByName('APPLICATION').AsString;

 

from grid I use:
    newValue := gridPermission.Columns.Items[0].Field.Text;
 

May be my sintax is wrong...

 

I see the new selected value only in DataChange event, but as consequence of  Post record...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...