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 SubCheck out the documentation in MSDN for the scripting runtime.