Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Macro substitution in VB
Message
De
26/04/2002 11:25:39
 
Information générale
Forum:
Visual Basic
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00647981
Message ID:
00649631
Vues:
10
>what is the command for macro substitution in vb

Depending on what you are trying to do, you might be able to use the script control like so:
Private Sub Command1_Click()

   
   Dim oSC As ScriptControl
   Dim iVal As Integer
   Set oSC = New ScriptControl
   oSC.Language = "VBScript"

   Dim toexe As String
   toexe = "4*5"
   iVal = oSC.Eval(toexe)

   MsgBox iVal, vbOKOnly, "Value of iVal"
clean_up:
   Set oSC = Nothing
End Sub
Check out the documentation in MSDN for the scripting runtime.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform