-
July 27th, 2002, 09:53 AM
#1
"((3+5)*4)-(40/2)-10)" =????
When user enter any string on TextBox like... "((3+5)*4)-(40/2)-10)".
how to make my program give the numerical result from the string.
-
July 27th, 2002, 10:12 AM
#2
Add 'Microsoft Access 8.0 Object Library' to your project's reference and this code:
Code:
private Sub Command1_Click()
Text1.Text = "((3+5)*4)-(40/2)-10)"
MsgBox Eval(Text1.Text)
End Sub
Marketing our skills - please participate in the survey and share your insights
-
-
July 27th, 2002, 11:02 AM
#3
Code:
'Add the Microsoft Script Control to your form and use the Eval function.
private Sub Command1_Click()
Debug.print ScriptControl1.Eval(Text1)
End Sub
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|