Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set VFP Form Property from VB6 OCX
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Contrôles ActiveX en VFP
Divers
Thread ID:
00684622
Message ID:
00685122
Vues:
33
This message has been marked as the solution to the initial question of the thread.
>Thank you. However, I'm not getting this to work. I put a command button on the OCX, and have a public subprocedure for click():
>
>Public Sub Command1_Click()
>
>End Sub
>
>In the VFP form properties window this method is available and I enter:
>
>*** ActiveX Control Method ***
>WAIT wind
>
>When I run the form and click the button nothing occurs. This is true for all VFP code I put in any methods of the OCX so far.
>
>Do I have to set something up for the VFP Code I add to the OCX methods in the property window to run?

Ah, I see what you're doing now. In order for this to work you need to declare an event in your VB control:
Event Click
Then, from the _Click event inside of VB, raise the event:
Private Sub Command1_Click()
  RaiseEvent Click
End Sub
Now when you drop this control on a VFP form, you can put code inside of the Click() event, and it will work the way you expect it to.

HTH
-Paul

RCS Solutions, Inc.
Blog
Twitter
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform