vikashbitm2010 Posted May 9, 2017 Posted May 9, 2017 Hi all, I want to return string from autoit script to the python code. Autoit: Exit("22 FE 45") -> not working Exit(1) -> Working Exit(0) -> Working python: import os res=os.system(autoitmine.exe) print "res",res I got some hint of @ExitCode macro, but dont know how to use it to get the string in python variable 'res'. Please resolve this issue for me if anyone knows about this.
Moderators JLogan3o13 Posted May 9, 2017 Moderators Posted May 9, 2017 Moved to the appropriate forum "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
Danyfirex Posted May 15, 2017 Posted May 15, 2017 (edited) Hello. you only can return an Integer using Exit. For return 22FE45 you could do something like this AutoIt Exit(2293317) ;0x22FE45 Python: print("%0.6X" % res) Saludos Edited May 15, 2017 by Danyfirex Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut
junkew Posted May 18, 2017 Posted May 18, 2017 I assume you can use stdin stdout lines = sys.stdin.readlines() www.autoitscript.com/autoit3/docs/functions/ConsoleWrite.htm FAQ 31 How to click some elements, FAQ 40 Test automation with AutoIt, Multithreading CLR .NET Powershell CMDLets
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