MikeK6MKF Posted March 5, 2015 Posted March 5, 2015 ; Here is the the fully qualified name of the executable I want to run in a variable Local $AcrobatEx = "C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" ; And here is the working Run statement in which I want to use $AcrobatEx instead of the whole fully qualified name string Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') I've tried a lot of different combinations to get this to Run, but my I can't seem to figure it out. Thanks in advance for your advice and suggestions.
MikahS Posted March 5, 2015 Posted March 5, 2015 (edited) What does the error message say, or does it even open the document at all? EDIT: Local $page = 2 run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="' & $page & '" "C:\Users\test\Desktop\Misc\Dealing_with_DLL.pdf"') Took me to 2nd page fine. When I put in an invalid page such as 300, it gives me an error and opens last page of document. If I mess up quotes, it will open reader, but not the PDF file. Edited March 5, 2015 by MikahS Snips & Scripts My Snips: graphCPUTemp ~ getENVvarsMy Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4 Feel free to use any of my code for your own use. Forum FAQ
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 (edited) It doesn't open it at all. Once I get past compiler errors, it doesn't do anything. I enforce the correct page number as there are 24 pages per PDF file. I'm trying to make changing the path and name of the Acrobat Reader executable easy to change in the variable declaration, and have that used by Run statements in the rest of the code. I'd like to do the same thing for the PDF directory string as well. Quite a newbie here, so I specialize in 'duh' questions at this point. Edited March 5, 2015 by MikeK6MKF
MikahS Posted March 5, 2015 Posted March 5, 2015 Hm. What are these compiler errors? Also, any script you haven't posted that could be maybe causing this problem? Snips & Scripts My Snips: graphCPUTemp ~ getENVvarsMy Scripts: Short-Order Encrypter - message and file encryption V1.6.1 ~ AuPad - Notepad written entirely in AutoIt V1.9.4 Feel free to use any of my code for your own use. Forum FAQ
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 It doesn't open it at all. Once I get past compiler errors, it doesn't do anything. I enforce the correct page number as there are 24 pages per PDF file. I'm trying to make changing the path and name of the Acrobat Reader executable easy to change in the variable declaration, and have that used by Run statements in the rest of the code. I'd like to do the same thing for the PDF directory string as well. Quite a newbie here, so I specialize in 'duh' questions at this point. What is the content of $page? This works fine for me: $page=3 ; And here is the working Run statement in which I want to use $AcrobatEx instead of the whole fully qualified name string Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ConsoleWrite('@@ Debug:' & '"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"' & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 (edited) Hi Jos, The value of $page is computed by: $utc = _GetUTC() $page = (($utc + 100) / 100 ) Func _GetUTC () Local $utc = 0, $ReadUTC = 0 ; Get current system time into $utc $utc = _Date_Time_GetSystemTime() ; Extract UTC hour and minute and concatentate them into $utc $utcHour = DllStructGetData($utc, "Hour") $utcMin = DllStructGetData($utc, "Minute") $utc = StringFormat("%02d%02d", $utcHour, $utcMin) ; now get any value in the UTC input field $ReadUTC = GUICtrlRead($UTCTime) ; Test for null value, i.e. nothing was entered in UTC field If StringRegExp($ReadUTC, "^d{4}$") = 0 Then Return $utc ; return $utc as value read from system clock Exit ; exit the function EndIf ; The UTC input is not null and is 4 digits, so the function continues ; The input string is formatted into the 4 digits $ReadUTC = StringFormat("%04d", GUICtrlRead($UTCTime)) ; If the GUI input is a number equal to or greater than 0 and less than 2400, the it's a valid UTC input, and it becomes the value of $utc ; Otherwise, $utc remains the value obtained from the system clock If $ReadUTC >= 0 And $ReadUTC < 2400 Then $utc = $ReadUTC ; $utc becomes the entered 4 digit value Return $utc ; $utc is returned to caller Exit ; exit the function Else EndIf EndFunc ;==>_GetUTC Sorry - should have used post code ... Edited March 5, 2015 by MikeK6MKF
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 expandcollapse popup; The K6TU TimeViewer ; Author: Mike, K6MKF ; Version 1.0 ; Last Update 3/5/2015 #include <Constants.au3> #include <GUIConstants.au3> #include <GUIConstantsEx.au3> #include <Date.au3> #include <WindowsConstants.au3> #include <String.au3> _Main() Func _Main() ; Well, I declare! Variables !! Global $UTCTime Local $idM80, $idM40, $idM30, $idM20, $idM17, $idM15, $idM12, $idM10, $idAll, $page, $utc, $iMsg Local $utcHour, $utcMin Local $AcrobatPath = "C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" Local $PDFDir = "C:\Predictions\" ; MsgBox(0,'',"The Reader Path is: " & $AcrobatPath ) ; MsgBox(0,'',"The PDF Dir Path is: " & $PDFDir ) ; Set the GUI Widget Name as "K6TU TimeViewer" GUICreate("K6TU TimeViewer", 630, 80, +1025, +20) ; GUICtrlCreateLabel("", 10, 100, 10) $idM80 = GUICtrlCreateButton("80M", 10, 10, 50, 20) $idM40 = GUICtrlCreateButton("40M", 80, 10, 50, 20) $idM30 = GUICtrlCreateButton("30M", 150, 10, 50, 20) $idM20 = GUICtrlCreateButton("20M", 220, 10, 50, 20) $idM17 = GUICtrlCreateButton("17M", 290, 10, 50, 20) $idM15 = GUICtrlCreateButton("15M", 360, 10, 50, 20) $idM12 = GUICtrlCreateButton("12M", 430, 10, 50, 20) $idM10 = GUICtrlCreateButton("10M", 500, 10, 50, 20) $idAll = GUICtrlCreateButton("ALL", 570, 10, 50, 20) $UTCTime = GUICtrlCreateInput("",10,50,40,20) GUICtrlCreateLabel("UTC", 58, 52, 30) ; GUI definition complete ; display the GUI GUISetState() Do $iMsg = GUIGetMsg() Select Case $iMsg = $idM80 ; 80M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ; Run('"' "& $AcrobatPath"'" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ; get the input page from the PDF file Case $iMsg = $idM40 ; 40M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') Case $iMsg = $idM30 ; 30M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_30.pdf"') Case $iMsg = $idM20 ; 20M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_20.pdf"') Case $iMsg = $idM17 ; 17M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_17.pdf"') Case $iMsg = $idM15 ; 15M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_15.pdf"') Case $iMsg = $idM12 ; 12M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_12.pdf"') Case $iMsg = $idM10 ; 10M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_10.pdf"') Case $iMsg = $idAll ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_30.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_20.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_17.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_15.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_12.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_10.pdf"') EndSelect Until $iMsg = $GUI_EVENT_CLOSE EndFunc ;==>_Main ; Resolve UTC, either from system clock or from valid UTC input in GUI ; Valid User input of UTC time overrides system clock UTC Func _GetUTC () Local $utc = 0, $ReadUTC = 0 ; Get current system time into $utc $utc = _Date_Time_GetSystemTime() ; Extract UTC hour and minute and concatentate them into $utc $utcHour = DllStructGetData($utc, "Hour") $utcMin = DllStructGetData($utc, "Minute") $utc = StringFormat("%02d%02d", $utcHour, $utcMin) ; now get any value in the UTC input field $ReadUTC = GUICtrlRead($UTCTime) ; Test for null value, i.e. nothing was entered in UTC field If StringRegExp($ReadUTC, "^\d{4}$") = 0 Then Return $utc ; return $utc as value read from system clock Exit ; exit the function EndIf ; The UTC input is not null and is 4 digits, so the function continues ; The input string is formatted into the 4 digits $ReadUTC = StringFormat("%04d", GUICtrlRead($UTCTime)) ; If the GUI input is a number equal to or greater than 0 and less than 2400, the it's a valid UTC input, and it becomes the value of $utc ; Otherwise, $utc remains the value obtained from the system clock If $ReadUTC >= 0 And $ReadUTC < 2400 Then $utc = $ReadUTC ; $utc becomes the entered 4 digit value Return $utc ; $utc is returned to caller Exit ; exit the function Else EndIf EndFunc ;==>_GetUTC Here's all the AutoIt code for this.
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 So can you add that debug line in your script to get the exact commandline being shelled? Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 (edited) I am embarrassed to say that I don't know how. Edited March 5, 2015 by MikeK6MKF
TheSaint Posted March 5, 2015 Posted March 5, 2015 You are still using the double quote for page= in the wrong place. I thought we'd cleared that up. Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') It should be Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A "page=' & $page & '" "C:\Predictions\UTC_40.pdf"') Are you also using a MsgBox to check what $page is? Make sure brain is in gear before opening mouth! Remember, what is not said, can be just as important as what is said. Spoiler What is the Secret Key? Life is like a Donut If I put effort into communication, I expect you to read properly & fully, or just not comment. Ignoring those who try to divert conversation with irrelevancies. If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it. I'm only big and bad, to those who have an over-active imagination. I may have the Artistic Liesense to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage)
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 Yes, I stopped thrashing when the page logic started working. I'll remove them and test it. Thanks.
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 Both forms of the Run statement produce the same successful result. Yours is much cleaner, of course, and will go into the code now. Thank you.
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 (edited) Added 2 debug lines in Case $iMsg = $idAll ... run it in SciTE and tell us what it shows in the SciTE Output pane. You probably have to convert $page to Integer, but lets see how the command looks. Jos expandcollapse popup; The K6TU TimeViewer ; Author: Mike, K6MKF ; Version 1.0 ; Last Update 3/5/2015 #include <Constants.au3> #include <GUIConstants.au3> #include <GUIConstantsEx.au3> #include <Date.au3> #include <WindowsConstants.au3> #include <String.au3> _Main() Func _Main() ; Well, I declare! Variables !! Global $UTCTime Local $idM80, $idM40, $idM30, $idM20, $idM17, $idM15, $idM12, $idM10, $idAll, $page, $utc, $iMsg Local $utcHour, $utcMin Local $AcrobatPath = "C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" Local $PDFDir = "C:\Predictions\" ; MsgBox(0,'',"The Reader Path is: " & $AcrobatPath ) ; MsgBox(0,'',"The PDF Dir Path is: " & $PDFDir ) ; Set the GUI Widget Name as "K6TU TimeViewer" GUICreate("K6TU TimeViewer", 630, 80, +1025, +20) ; GUICtrlCreateLabel("", 10, 100, 10) $idM80 = GUICtrlCreateButton("80M", 10, 10, 50, 20) $idM40 = GUICtrlCreateButton("40M", 80, 10, 50, 20) $idM30 = GUICtrlCreateButton("30M", 150, 10, 50, 20) $idM20 = GUICtrlCreateButton("20M", 220, 10, 50, 20) $idM17 = GUICtrlCreateButton("17M", 290, 10, 50, 20) $idM15 = GUICtrlCreateButton("15M", 360, 10, 50, 20) $idM12 = GUICtrlCreateButton("12M", 430, 10, 50, 20) $idM10 = GUICtrlCreateButton("10M", 500, 10, 50, 20) $idAll = GUICtrlCreateButton("ALL", 570, 10, 50, 20) $UTCTime = GUICtrlCreateInput("",10,50,40,20) GUICtrlCreateLabel("UTC", 58, 52, 30) ; GUI definition complete ; display the GUI GUISetState() Do $iMsg = GUIGetMsg() Select Case $iMsg = $idM80 ; 80M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ; Run('"' "& $AcrobatPath"'" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ; get the input page from the PDF file Case $iMsg = $idM40 ; 40M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') Case $iMsg = $idM30 ; 30M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_30.pdf"') Case $iMsg = $idM20 ; 20M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_20.pdf"') Case $iMsg = $idM17 ; 17M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_17.pdf"') Case $iMsg = $idM15 ; 15M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_15.pdf"') Case $iMsg = $idM12 ; 12M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_12.pdf"') Case $iMsg = $idM10 ; 10M button is clicked ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_10.pdf"') Case $iMsg = $idAll ; calculate page number from $utc value $utc = _GetUTC() $page = (($utc + 100) / 100 ) ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $page = ' & $page & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"') ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : ''"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="''& $page &''" "C:\Predictions\UTC_80.pdf"'' = ' & '"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_80.pdf"' & @CRLF & '>Error code: ' & @error & @CRLF) ;### Debug Console Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_30.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_20.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_17.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_15.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_12.pdf"') Sleep (500) Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_10.pdf"') EndSelect Until $iMsg = $GUI_EVENT_CLOSE EndFunc ;==>_Main ; Resolve UTC, either from system clock or from valid UTC input in GUI ; Valid User input of UTC time overrides system clock UTC Func _GetUTC () Local $utc = 0, $ReadUTC = 0 ; Get current system time into $utc $utc = _Date_Time_GetSystemTime() ; Extract UTC hour and minute and concatentate them into $utc $utcHour = DllStructGetData($utc, "Hour") $utcMin = DllStructGetData($utc, "Minute") $utc = StringFormat("%02d%02d", $utcHour, $utcMin) ; now get any value in the UTC input field $ReadUTC = GUICtrlRead($UTCTime) ; Test for null value, i.e. nothing was entered in UTC field If StringRegExp($ReadUTC, "^\d{4}$") = 0 Then Return $utc ; return $utc as value read from system clock Exit ; exit the function EndIf ; The UTC input is not null and is 4 digits, so the function continues ; The input string is formatted into the 4 digits $ReadUTC = StringFormat("%04d", GUICtrlRead($UTCTime)) ; If the GUI input is a number equal to or greater than 0 and less than 2400, the it's a valid UTC input, and it becomes the value of $utc ; Otherwise, $utc remains the value obtained from the system clock If $ReadUTC >= 0 And $ReadUTC < 2400 Then $utc = $ReadUTC ; $utc becomes the entered 4 digit value Return $utc ; $utc is returned to caller Exit ; exit the function Else EndIf EndFunc ;==>_GetUTC Edited March 5, 2015 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 (edited) You are still using the double quote for page= in the wrong place. I thought we'd cleared that up. Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A page="'& $page &'" "C:\Predictions\UTC_40.pdf"') It should be Run('"C:\Program Files (x86)\Adobe\Reader 11.0\Reader\AcroRd32.exe" /A "page=' & $page & '" "C:\Predictions\UTC_40.pdf"') Are you also using a MsgBox to check what $page is? I tried it and the syntax was working for me in its original form. Jos Edited March 5, 2015 by Jos TheSaint 1 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 The page logic seems to consistently return correct results. Now I'm trying to make it more flexible by putting Paths and Directories in variables.
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 The page logic seems to consistently return correct results. Now I'm trying to make it more flexible by putting Paths and Directories in variables. So ... what was the output commandline? Was it correct? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 (edited) I'm getting more embarrassed by the moment. I put the ConsoleWrite statement in my code, but haven't a clue where to see the output. My internet searches lead me to scripts read the STDOUT - Is this way to see it? Edited March 5, 2015 by MikeK6MKF
TheSaint Posted March 5, 2015 Posted March 5, 2015 I tried it and the syntax was working for me in its original form. Jos No worries, I haven't tried it, but just noticed it had reverted. Plus, I thought others had indicated this was important. So alas, no quick easy solution. Make sure brain is in gear before opening mouth! Remember, what is not said, can be just as important as what is said. Spoiler What is the Secret Key? Life is like a Donut If I put effort into communication, I expect you to read properly & fully, or just not comment. Ignoring those who try to divert conversation with irrelevancies. If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it. I'm only big and bad, to those who have an over-active imagination. I may have the Artistic Liesense to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage)
MikeK6MKF Posted March 5, 2015 Author Posted March 5, 2015 I'm getting more embarrassed by the moment. I put the ConsoleWrite statement in my code, but haven't a clue where to see the output. My internet searches lead me to scripts read the STDOUT - Is this way to see it? Or do I need to have another process running to see STDOUT?
Developers Jos Posted March 5, 2015 Developers Posted March 5, 2015 Open the script I posted in SciTE and hit F5 to run it. Select the correct open and you should see the output in the bottom-halve of the screen. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
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