Jump to content

new value of DBComboBox in a grid


Phxtecno

Recommended Posts

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

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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...

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...