Information générale
Catégorie:
Codage, syntaxe et commandes
Titre:
Equivalent Commands
In VB there is a Set command for objects. Once set you can then use that as an object reference. Let me give you an example:
Set xl = CreateObject("Excel.Application")
You can now use that as your object reference. Like:
xl.Workbooks.Open("C:\Spreadsheets\Sales.xls")
xl.ActiveWorkbook.ActiveSheet.Range("B2").Value
I am looking for an equivelent in VFP. I can fake it by stuffing a variable and then using the macro substitution but this doesn't work in all cases, like this:
Genie = LoadCharacter("Genie")
Please note to fake it I must ust the double period, maybe someone could explain that one also.
&Genie..Play("Move",100,200)
&Genie..Speak("I don't know what I'm doing")
The reason that I am asking is that the genie returns a handle and I can't seem to grab it and use it like the VB example shows.
TIA
DJ
Suivant
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