Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Primary and foreign key fun with combos and grids?
Message
 
To
01/07/2002 12:46:16
Vladimir Zhuravlev
Institute of the Physics of Earth,Russia
Moscow Region, Russia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00673883
Message ID:
00674108
Views:
32
>Chris
>I do this in the following way
>column with combo, sparce .t. ( combo is shown only in active cell)
>column bound=.f.
>there is relation between parent table ( grid source and chield for rowsorce of the combo , ) In the combo gotfocus
>I do
>if not parent.key=chield.key or seek(parent.key,'chield','key')
>this.displayvalue=chiled.filedtoshow
>else
>this.displayvalue=''
>endif
>In click of the combo is regular code
>replace parent.key with chield.key in parent
>It works for me for years
>Best wishes, Vladimir
>Setting bound to t cause problem , if chiled table has gaps in the keys
Ok thanks Vladimir - I must have made it sound like the combo was in a grid column but it's not - it is just on the form... the grid and combo are also on a pageframe which adds a little to the problem - I am not sure it's refreshing correctly ever though I have tried thisform.pageframe.page3.cmbCompanies.refresh(), thisform.pageframe.refresh(), and thisform.refresh()

I have done this also... thisform.pageframe.page3.cmbCompanies.value = alltrim(v_companynames.co_name) and still I have nothing showing in the combo...
Thanks again - any other advice gratefully received!
Chris Maiden
Email
Web
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform