IanN1990 Posted March 15, 2017 Share Posted March 15, 2017 Hi, I am having some issues displaying the STDOUT Stream within command prompt Eample.exe - Code #AutoIt3Wrapper_Change2CUI=Y sleep(1000) ConsoleWrite("Test") sleep(1000) Cmd Start /Wait C:\Example.exe The command prompt successfully runs and waits for the program to close but doesn't display the console written information? Help file says "The purpose for this function is to write to the STDOUT stream. Many popular text editors can read this stream. Scripts compiled as Console applications also have a STDOUT stream.This does not write to a DOS console unless the script is compiled as a console application." and https://www.autoitscript.com/wiki/AutoIt3Wrapper_Directives shows #AutoIt3Wrapper_Change2CUI (Y/N) Change output program to CUI in stead of GUI. N So where have i gone wrong Link to comment Share on other sites More sharing options...
water Posted March 15, 2017 Share Posted March 15, 2017 (edited) When running a slightly modified version of your script (compiled and double clicked in Windows Explorer) it displays the expected values: #AutoIt3Wrapper_Change2CUI=Y Sleep(1000) Global $iDataWritten = ConsoleWrite("Test") Sleep(1000) MsgBox(0, "Result", "Bytes written " & $iDataWritten) Edited March 15, 2017 by water My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
IanN1990 Posted March 15, 2017 Author Share Posted March 15, 2017 (edited) Just to confirm. When you double click the test.exe it opens up a dos display? As if that is the case. Mine does not :S Edited March 15, 2017 by IanN1990 Link to comment Share on other sites More sharing options...
IanN1990 Posted March 15, 2017 Author Share Posted March 15, 2017 (edited) I completely uninstalled and reinstalled Autoit 3.5.4 but had the same issue. I found though with SciTE4AutoIt3.exe installed it works as you describe it. Edited March 15, 2017 by IanN1990 Link to comment Share on other sites More sharing options...
water Posted March 15, 2017 Share Posted March 15, 2017 There is no AutoIt version 3.5.4. Are you talking about the SciTE version? What's the version of AutoIt you run? MsgBox(0, "", @AutoItVersion) Do you run the full SciTE version or the light version that comes with AutoIt? My UDFs and Tutorials: Spoiler UDFs:Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsOutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - DownloadOutlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - WikiPowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - WikiTask Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs:Excel - Example Scripts - WikiWord - Wiki Tutorials:ADO - WikiWebDriver - Wiki Link to comment Share on other sites More sharing options...
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