Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Local View doesn't return row
Message
De
21/01/2006 22:05:49
Steve Summers
Pima County Superior Court
Tucson, Arizona, États-Unis
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01088535
Message ID:
01089181
Vues:
23
>>I have done some testing since this post. The code works great when I test the class by it's self. This makes me think it’s an environment issue. This project was a VFP6 project and I'm updating it to VFP9.
>
>The first thing I owould do is put the view's name in the requery() call;
>
>Requery("View1")
>
>See if that fixes it. View1 may not be the selected work area when the requery is executed.

Jim. I just thought you might like to know what this issue turned out to be. I traced it back to the addobject method. You get some weird behavior when you add ole control directly to a class without first subclassing. The VFP9 ADDOBJECT help states:

If you plan to distribute run-time applications which add ActiveX Controls requiring License key information (for example, Microsoft Treeview and Listview controls), you should not use the AddObject(.....cOLEClass) method. Instead, create and save a subclass of your ActiveX Control to a VCX class library. Then, at run time you can use the AddObject (or NewObject) method to add this OleControl class containing your control.

I was using the MS treeview control. After I subclassed the view started working.

BTW I'm sure you don't remember but You were my VFP instructor in San Francisco back in 1992.
Thanks for your continued support of this excellent product!
Thanks in advance or I hope this helps!

[STS]
:>
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform