General information
Category:
Forms & Form designer
Also make sure you put the code into the load event not the init event of the form.
>The FAQ entitled: 'How do I ensure my forms are pointing to the correct tables' dated 24/06/99 provides a means for modifying the path of a database that is declared in the DE. Works great!
>
>But..I recently tried to use one of MS's canned forms (the simple one you get when use the form wizard) and the form broke when I tried to modify the database path in the manner cited above.
>
>It broke because the init of one of the form's controls (the pushbuttons) tries to access a cursor ... which hasn't been created yet since, as per the cited ref, files are not opened until the form's init fires.
>
>(...thus illustrating, among other things, the pitfalls of mucking with precanned classes...)
>
>I discovered that I could mitigate this problem by allowing the DE to automatically open the files, and instead, modify the database path of the cursor in the DE's beforeopentables event.
>
>Is this another acceptable means for achieving the same result as in the cited FAQ?
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only