Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
What table can't it access?
Message
 
 
À
04/11/1998 16:34:12
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Divers
Thread ID:
00154499
Message ID:
00154567
Vues:
21
>>>>>>I have a form with a pageframe on it. After I call my router class and come back, it sets page 2 to be active. If I then click on page 1, I get the error "Can't access the selected table". It has an OK button and a HELP button. No SUSPEND button. Using messageboxes, I narrowed down where it happens: between the deactivate of page 2 and the activate of page 1.
>>>>>>
>>>>>>What's in there? I don't have code in any of the other methods of either page, so even if there's an event that runs between the two, there's no code there to run.
>>>>>>
>>>>>>Also, after I click OK, the program continues running fine. If it couldn't find a table, it must not be an important one because there's no visible problems after that.
>>>>>>
>>>>>>I realize this is a hard one to answer without seeing the form, but I'm hoping someone out there has run into this before.
>>>>>>
>>>>>>Thanks,
>>>>>>
>>>>>>-Michelle
>>>>>
>>>>>One possible reason for such message is recollected Combo.Rowsource.
>>>>
>>>>
>>>>There is a combobox on each of the pages. What do you mean by "recollected"?
>>>>
>>>>Thanks,
>>>>
>>>>-Michelle
>>>
>>>If you base combo on cursor and recollect records to this cursor (e.g. SELECT_SQL fires from Page.Activate event) then it's safer to 'disconnect' combo from rowsource before SELECT (combo.rowsource="") and restore it after.
>>
>>I was hoping that was it, and I did actually set the rowsource for the combo in the activate, but it's still doing it.
>>
>>BUT, it DOES have something to do with the comboboxes since it worked when I took them off.
>>
>>Hmmmm....
>>
>>Thanks,
>>
>>-Michelle
>
>So, you can remove them and then add them back step-by-step.

I did. It's the code that sets the rowsource in the activate method that's doing it. But setting the rowsource to "" didn't help. Do you have any other ideas? I don't know where else to put the code. I need it to remake the cursor when the page is activated.

Thanks,

-Michelle
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform