Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Datalist with Datagrid - date update in datagrid colum

Status
Not open for further replies.

fawaz

Programmer
Mar 3, 2001
16
IN
I am having a datagrid (using VB6.0 sp.06 /forms created with vb5.00 but contorls updated ver vb6.0) with columns having Button. When I click the Button a listbox is visible and it is positioned at same row dropping down from the next column (So the column which is going to updated is visible). This is I done with Datagrid.row.top properties.

It is working Fine. But when I double click the item in listbox, that selected listed item is updated to the column and the list box is made visible=false. That is what I wanted. But the problem is that again the selected list item is updated on the column in the datagrid where the mousepointer is rest (when selecting item in the list box) justlike mouseclick leaked from listbox to datagrid and updated column with selected listbox item.

How I can avoide the second update?
 
One solution and not necessarily the best, is to set a flag like blnManualComboUpdate to true as soon as the first update went through and ignore the second click if the flag is positive. The problem is that you then have to make sure that the blnManualComboUpdate is always properly set and properly cleared.
-Max
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top