sr243 Posted March 28, 2008 Posted March 28, 2008 I am trying to write a script which uses the number() function.Basically, the program is supposed grab the clipboard, which will already have a mathematical expression (e.g "5 + 5") and then solve it and send() the answer.This is what I have so far:$a=clipget()$b=number($a)send($However, because the expression in the clipboard is read as a string, the number function isn't solving the expression.Instead, when I have an expression like "256 - 4", it would simply output "256" as it reads it as a string and cuts everything after the sign.Any hints on how to solve this problem?
cppman Posted March 28, 2008 Posted March 28, 2008 $a = "256 - 4"; ClipGet() MsgBox(0, "", Execute($a))I think your looking for the Execute function. Miva OS Project
FreeFry Posted March 28, 2008 Posted March 28, 2008 (edited) Try using Execute instead:Send(Execute(ClipGet()))Edit:Doh, cppman beat me too it. Edited March 28, 2008 by FreeFry
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now