Jump to content

How to get information from(string) script?


Recommended Posts

Hi craft,

I am developing application in vc++ 6.0. i want run script file from vc++.but i need to pass values from vc++ to script and get back (string) from of script after exit of sccript to vc++.How?

if any one know? pl help me

sample is script files name is word.au3

If $CmdLine[0] = 0 then

exit(1)

endif

$DN=Int($CmdLine[1])

MyDouble()

Exit($dn) ?

Func MyDouble()

Run("notepad.exe")

WinWaitActive("Untitled - Notepad")

sleep(500)

Send("Hello from ANJI.M Example."& $CmdLine[1] & "{ENTER}") ;dispmet command

send("1 2 3 4 5 6 7 8 9 10{ENTER}")

Sleep(3000)

Send("+{UP 2}")

Sleep(500)

Send("^c")

$DN=ClipGet()

Send("!f")

Send("x")

Sleep(1000)

WinWaitActive("Notepad", "No")

Send("n")

Sleep(1000)

WinWaitClose("Untitled - Notepad")

MsgBox(0,"your number is present",$DN)

return $DN

EndFunc

Edited by Ramanji.M
Link to comment
Share on other sites

Hi craft,

I am developing application in vc++ 6.0. i want run script file from vc++.but i need to pass values from vc++ to script and get back (string) from of script after exit of sccript to vc++.How?

if any one know? pl help me

sample is script files name is word.au3

If $CmdLine[0] = 0 then

exit(1)

endif

$DN=Int($CmdLine[1])

MyDouble()

Exit($dn) ?

Func MyDouble()

Run("notepad.exe")

WinWaitActive("Untitled - Notepad")

sleep(500)

Send("Hello from ANJI.M Example."& $CmdLine[1] & "{ENTER}") ;dispmet command

send("1 2 3 4 5 6 7 8 9 10{ENTER}")

Sleep(3000)

Send("+{UP 2}")

Sleep(500)

Send("^c")

$DN=ClipGet()

Send("!f")

Send("x")

Sleep(1000)

WinWaitActive("Notepad", "No")

Send("n")

Sleep(1000)

WinWaitClose("Untitled - Notepad")

MsgBox(0,"your number is present",$DN)

return $DN

EndFunc

You could Wite it to a text file FileWrite()

You Could Write it to the registry RegWrite()

You Could put it on the clipboard ClipPut()

You could also use the Stdin/out method use the beta version of AutoIT

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...