Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Please translate VB directions
Message
 
À
19/09/2000 18:45:29
Cindy Winegarden
Duke University Medical Center
Durham, Caroline du Nord, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00418306
Message ID:
00418314
Vues:
24
>>>>>>>>Open VB. Select Project | References
>>>>>>>>Select the PllrSrvr 2.0 Type Library check box
>>>>>>>>(This establishes a reference to PllrSrvrLib which contains PllrApi)

This is a VB way to automatically include an active X/COM component in the project. As long as the component is registered on the client machine (many ways to do this, including the VFP Setup Wizard) you will be fine in VFP. In VB, this approach allows for early binding...

>>>>>>>>To view the methods in PllrApi select View | Object Browser
You can use an Outlook application's VB editor, I think, if you don't have VB. Unfortunately, I don't know a straightforward way in VFP to look under the hood of such a component.

>>>>>I have added "C:\Program Files\...\PllrSrvr.tlb"
>>>>>to my class browser and can see PllrSrvr in the
>>>>>right pane with PllrApi showing as a class and
>>>>>iPllrApi listed as an "interface" with methods
>>>>>(open, save) and "tags" which look to me like
>>>>>properties (field delimiter, record delimiter
>>>>>- these are customizable in Pillar.)

Hmmmm... okay, maybe you found a way that I wasn't aware of!

>>>>>Declare PllrApi as an object in your VB code
>>>>>Public Pllr AS PllrSrvrLib.PllrApi
>>>>>Sub Main()
>>>>> Set Pllr = New PllrSrvrLib.PllrApi
>>>>> frmMain.Show
>>>>>End Sub

This is optional, and just a way to create a high-level object reference so that you don't have to create an instance every time you want to use it. Not a bad idea in VFP either.... If your application object is named goApp, you might have the following code in the App startup routine:
goApp.Pllr = createobject("pllrSrvrLib.PllrApi")



Hope this helps...
The whole problem with the world is that fools and fanatics are always so certain of themselves, but wiser people so full of doubts. - Bertrand Russell
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform