Information générale
Titre:
FYI - Combobox issues in VFP9
Versions des environnements
Network:
Windows 2000 Server
FYI - Combobox issues in VFP9
ISSUE:
After a VFP9 upgrade of a legacy application that was created in VFP5, and updated to VFP7, we began to experiences “Cannot access the selected table…” errors (error #1152) with combo box and list box controls on forms with multiple pages on page frames. These errors would occur after changing pages (and interestingly, by-passed the form’s on error event). All of the errors occurred with controls whose RowSourceType was set to 3 - SQL statement.
DISCOVERY – The SQL SELECT statement in the controls in question were created using the same cursor name (and were probably created using copy and paste). The errors only occurred after changing pages then attempting to return to the page with the control(s) in question. The error did NOT occur where the controls which created cursors with the same cursor name were on the same page.
RESOLUTION:
Modify the SELECT statements to ensure unique cursor names.
CONCLUSION:
As these errors were not raised in VFP5 & VFP7, VFP9 must have some addition that not only knows which Data Session the controls cursor was created in but also knows which Work Space it is linked to, and in my opinion the is A GOOD THING since I did find one form which had combo boxes on different pages with different SELECT statements being created into the same cursor name.
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement