JayT Posted September 29, 2021 Posted September 29, 2021 (edited) _IECreate does not seem to be working any longer not sure why maybe because it is being phased out for edge however, I tried using Chrome.exe ShellExecute("chrome.exe", "http://rtfm.com --new-window --start-fullscreen") and for some reason it does not paste the entire string with all the variables? The URL ends at "Smith"? any help would be very much appreciated. expandcollapse popup#Region ### START Koda GUI section ### Form= $Form1_1 = GUICreate("Camping Reservation Checker V3.0", 695, 629, -1, -1) $Pic1 = GUICtrlCreatePic("images\Camper.jpg", 16, 16, 231, 153) $Group1 = GUICtrlCreateGroup("", 256, 16, 345, 153) $Heading = GUICtrlCreateLabel("Select a Park", 328, 40, 79, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") $Combo1 = GUICtrlCreateCombo("Smith Point", 440, 40, 145, 25) GUICtrlSetData(-1, "Cupsogue|Indian+Island|Montauk|Sears+bellows|Shinnecock+East|Southaven|West+Hills") $hookups = GUICtrlCreateCombo("Sewer", 440, 72, 145, 25) GUICtrlSetData(-1, "Basic|Electric|Outer+Beach") $Label3 = GUICtrlCreateLabel("Select Hookup", 328, 72, 84, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") $Number_of_Nights = GUICtrlCreateCombo("4", 440, 104, 145, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData(-1, "5|6|7|8|9|10|11|12|13|14") $Label2 = GUICtrlCreateLabel("Number of Nights", 328, 104, 101, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") GUICtrlCreateGroup("", -99, -99, 1, 1) $Submit = GUICtrlCreateButton("Click to Seaarch", 354, 558, 149, 46) GUICtrlSetFont(-1, 8, 400, 0, "MV Boli") $Label1 = GUICtrlCreateLabel("Check All Availability", 352, 187, 186, 28) GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif") $Date = GUICtrlCreateLabel("Enter Date:", 265, 235, 70, 20) GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif") $Month = GUICtrlCreateCombo("Month", 337, 235, 65, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData($Month,"01|02|03|04|05|06|07|08|09|10|11|12|") $Day = GUICtrlCreateCombo("Day", 409, 235, 57, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData($Day, "01|02|03|04|05|06|07|08|09|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30") $Year = GUICtrlCreateCombo("2021", 489, 235, 65, 25) GUICtrlSetData(-1, "2021|2022") $Checkbox1 = GUICtrlCreateCheckbox("Site 230", 301, 390, 62, 17) $Checkbox2 = GUICtrlCreateCheckbox("Site 232", 301, 414, 62, 17) $Checkbox3 = GUICtrlCreateCheckbox("Site 234", 389, 414, 62, 17) $Checkbox4 = GUICtrlCreateCheckbox("Site 236", 301, 438, 61, 17) $Checkbox5 = GUICtrlCreateCheckbox("Site 238", 389, 438, 64, 17) $Checkbox6 = GUICtrlCreateCheckbox("Site 240", 301, 462, 60, 17) $Checkbox7 = GUICtrlCreateCheckbox("Site 242", 389, 462, 63, 17) $Checkbox8 = GUICtrlCreateCheckbox("Site 244", 301, 486, 59, 17) $Checkbox9 = GUICtrlCreateCheckbox("Site 246", 389, 486, 63, 17) $Checkbox10 = GUICtrlCreateCheckbox("Site 248", 301, 510, 62, 17) $Checkbox11 = GUICtrlCreateCheckbox("Site 250", 389, 510, 63, 17) $Checkbox12 = GUICtrlCreateCheckbox("Site 245", 493, 366, 64, 17) $Checkbox13 = GUICtrlCreateCheckbox("Site 247", 493, 390, 60, 17) $Checkbox14 = GUICtrlCreateCheckbox("Site 249", 493, 414, 63, 17) $Checkbox15 = GUICtrlCreateCheckbox("Site 251", 493, 438, 61, 17) $Checkbox16 = GUICtrlCreateCheckbox("Site 253", 493, 462, 64, 17) $Checkbox17 = GUICtrlCreateCheckbox("Site 255", 493, 486, 60, 17) $Checkbox18 = GUICtrlCreateCheckbox("Site 257", 493, 510, 63, 17) $Label4 = GUICtrlCreateLabel("Ocean Side", 303, 339, 71, 20) GUICtrlSetFont(-1, 10, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) $Label5 = GUICtrlCreateLabel("Inner Side", 494, 338, 64, 20) GUICtrlSetFont(-1, 10, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) $Label6 = GUICtrlCreateLabel(" Select Below For Smith Point Beach Top Sites !", 288, 280, 317, 21) GUICtrlSetFont(-1, 10, 400, 0, "MV Boli") $Label7 = GUICtrlCreateLabel("These Sites Are For SmithPoint Camping Only", 321, 313, 232, 17) GUICtrlSetFont(-1, 8, 400, 4, "MS Sans Serif") $MonthCal1 = GUICtrlCreateMonthCal("2021/03/03", 16, 184, 229, 196) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Combo1 If GUICtrlRead($combo1) = ("Smith Point") Then GUICtrlSetState ($Checkbox1, $GUI_ENABLE) GUICtrlSetState($Checkbox2, $GUI_ENABLE) GUICtrlSetState($Checkbox3, $GUI_ENABLE) GUICtrlSetState($Checkbox4, $GUI_ENABLE) GUICtrlSetState($Checkbox5, $GUI_ENABLE) GUICtrlSetState($Checkbox6, $GUI_ENABLE) GUICtrlSetState($Checkbox7, $GUI_ENABLE) GUICtrlSetState($Checkbox8, $GUI_ENABLE) GUICtrlSetState($Checkbox9, $GUI_ENABLE) GUICtrlSetState($Checkbox10, $GUI_ENABLE) GUICtrlSetState($Checkbox11, $GUI_ENABLE) GUICtrlSetState($Checkbox12, $GUI_ENABLE) GUICtrlSetState($Checkbox13, $GUI_ENABLE) GUICtrlSetState($Checkbox14, $GUI_ENABLE) GUICtrlSetState($Checkbox15, $GUI_ENABLE) GUICtrlSetState($Checkbox16, $GUI_ENABLE) GUICtrlSetState($Checkbox17, $GUI_ENABLE) GUICtrlSetState($Checkbox18, $GUI_ENABLE) Else GUICtrlSetState($Checkbox1, $GUI_DISABLE) GUICtrlSetState($Checkbox2, $GUI_DISABLE) GUICtrlSetState($Checkbox3, $GUI_DISABLE) GUICtrlSetState($Checkbox4, $GUI_DISABLE) GUICtrlSetState($Checkbox5, $GUI_DISABLE) GUICtrlSetState($Checkbox6, $GUI_DISABLE) GUICtrlSetState($Checkbox7, $GUI_DISABLE) GUICtrlSetState($Checkbox8, $GUI_DISABLE) GUICtrlSetState($Checkbox9, $GUI_DISABLE) GUICtrlSetState($Checkbox10, $GUI_DISABLE) GUICtrlSetState($Checkbox11, $GUI_DISABLE) GUICtrlSetState($Checkbox12, $GUI_DISABLE) GUICtrlSetState($Checkbox13, $GUI_DISABLE) GUICtrlSetState($Checkbox14, $GUI_DISABLE) GUICtrlSetState($Checkbox15, $GUI_DISABLE) GUICtrlSetState($Checkbox16, $GUI_DISABLE) GUICtrlSetState($Checkbox17, $GUI_DISABLE) GUICtrlSetState($Checkbox18, $GUI_DISABLE) EndIf Case $Submit sleep (1000) $Date2 = GUICtrlRead ($Day) $Date1 = GUICtrlRead ($Month) $Date3 = GUICtrlRead ($Year) $location = GUICtrlRead ($Combo1) $hookup = GUICtrlRead ($hookups) $nights = GUICtrlRead ($Number_of_Nights) GUICtrlSetData($Day, "01|02|03|04|05|06|07|08|09|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30") GUICtrlSetData($Month,"01|02|03|04|05|06|07|08|09|10|11|12|") Call ("Example") EndSwitch WEnd Example() Func Example() Local $sCompare = 'data-icon-primary="ui-icon-plusthick"' ; Get page 1 Local $dData = InetRead("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD) Local $sData = BinaryToString($dData) ;ConsoleWrite ($sData & @CRLF) Local $aPage = StringRegExp($sData, '<option value="(\d+)', 3) ;_ArrayDisplay($aPage) Local $nPage = $aPage[UBound($aPage) - 1] Local $aTotal = StringRegExp($sData, '(?s)data-icon-primary="ui-icon-plusthick".*?data-title="Site\/Item #"[^\d]+(\d+)', 3) Local $iTotal = UBound($aTotal) Local $aPart ; loop thru all pages using $i as page indicator For $i = 2 To $nPage $dData = InetRead("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=" & $i & "&gotopagenow=yes&gotopage=&module=RN&multiselectlist_value=", $INET_FORCERELOAD) $sData = BinaryToString($dData) $aPart = StringRegExp($sData, '(?s)data-icon-primary="ui-icon-plusthick".*?data-title="Site\/Item #"[^\d]+(\d+)', 3) $iTotal += UBound($aPart) _ArrayConcatenate($aTotal, $aPart) Next Return SetExtended($iTotal, $aTotal) $sData = BinaryToString($dData) StringReplace($sData, $sCompare, $sCompare) $iTotal += @extended $verify = MsgBox(4, $itotal & " Sites Available", "There Are " & $iTotal & " Sites Available at " & $location & " with " & $hookup & ". " & @CRLF & @CRLF & " Do you want to continue to the reservation page?") Select Case $verify = 6 ; YES, proceed with step 1 _IECreate("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD) Case $verify = 7 ; NO thanks EndSelect EndFunc ;==>Example Edited September 29, 2021 by JayT
Subz Posted September 29, 2021 Posted September 29, 2021 (edited) Try using single quotes/double quotes ShellExecute("chrome.exe", '"http://rtfm.com" --new-window --start-fullscreen') Edited September 29, 2021 by Subz
JayT Posted September 29, 2021 Author Posted September 29, 2021 expandcollapse popup#Region ### START Koda GUI section ### Form= $Form1_1 = GUICreate("Camping Reservation Checker V3.0", 695, 629, -1, -1) $Pic1 = GUICtrlCreatePic("images\Camper.jpg", 16, 16, 231, 153) $Group1 = GUICtrlCreateGroup("", 256, 16, 345, 153) $Heading = GUICtrlCreateLabel("Select a Park", 328, 40, 79, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") $Combo1 = GUICtrlCreateCombo("Smith Point", 440, 40, 145, 25) GUICtrlSetData(-1, "Cupsogue|Indian+Island|Montauk|Sears+bellows|Shinnecock+East|Southaven|West+Hills") $hookups = GUICtrlCreateCombo("Sewer", 440, 72, 145, 25) GUICtrlSetData(-1, "Basic|Electric|Outer+Beach") $Label3 = GUICtrlCreateLabel("Select Hookup", 328, 72, 84, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") $Number_of_Nights = GUICtrlCreateCombo("4", 440, 104, 145, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData(-1, "5|6|7|8|9|10|11|12|13|14") $Label2 = GUICtrlCreateLabel("Number of Nights", 328, 104, 101, 19) GUICtrlSetFont(-1, 9, 400, 0, "Arial") GUICtrlCreateGroup("", -99, -99, 1, 1) $Submit = GUICtrlCreateButton("Click to Seaarch", 354, 558, 149, 46) GUICtrlSetFont(-1, 8, 400, 0, "MV Boli") $Label1 = GUICtrlCreateLabel("Check All Availability", 352, 187, 186, 28) GUICtrlSetFont(-1, 14, 400, 0, "MS Sans Serif") $Date = GUICtrlCreateLabel("Enter Date:", 265, 235, 70, 20) GUICtrlSetFont(-1, 10, 400, 0, "MS Sans Serif") $Month = GUICtrlCreateCombo("Month", 337, 235, 65, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData($Month,"01|02|03|04|05|06|07|08|09|10|11|12|") $Day = GUICtrlCreateCombo("Day", 409, 235, 57, 25, BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL)) GUICtrlSetData($Day, "01|02|03|04|05|06|07|08|09|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30") $Year = GUICtrlCreateCombo("2021", 489, 235, 65, 25) GUICtrlSetData(-1, "2021|2022") $Checkbox1 = GUICtrlCreateCheckbox("Site 230", 301, 390, 62, 17) $Checkbox2 = GUICtrlCreateCheckbox("Site 232", 301, 414, 62, 17) $Checkbox3 = GUICtrlCreateCheckbox("Site 234", 389, 414, 62, 17) $Checkbox4 = GUICtrlCreateCheckbox("Site 236", 301, 438, 61, 17) $Checkbox5 = GUICtrlCreateCheckbox("Site 238", 389, 438, 64, 17) $Checkbox6 = GUICtrlCreateCheckbox("Site 240", 301, 462, 60, 17) $Checkbox7 = GUICtrlCreateCheckbox("Site 242", 389, 462, 63, 17) $Checkbox8 = GUICtrlCreateCheckbox("Site 244", 301, 486, 59, 17) $Checkbox9 = GUICtrlCreateCheckbox("Site 246", 389, 486, 63, 17) $Checkbox10 = GUICtrlCreateCheckbox("Site 248", 301, 510, 62, 17) $Checkbox11 = GUICtrlCreateCheckbox("Site 250", 389, 510, 63, 17) $Checkbox12 = GUICtrlCreateCheckbox("Site 245", 493, 366, 64, 17) $Checkbox13 = GUICtrlCreateCheckbox("Site 247", 493, 390, 60, 17) $Checkbox14 = GUICtrlCreateCheckbox("Site 249", 493, 414, 63, 17) $Checkbox15 = GUICtrlCreateCheckbox("Site 251", 493, 438, 61, 17) $Checkbox16 = GUICtrlCreateCheckbox("Site 253", 493, 462, 64, 17) $Checkbox17 = GUICtrlCreateCheckbox("Site 255", 493, 486, 60, 17) $Checkbox18 = GUICtrlCreateCheckbox("Site 257", 493, 510, 63, 17) $Label4 = GUICtrlCreateLabel("Ocean Side", 303, 339, 71, 20) GUICtrlSetFont(-1, 10, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) $Label5 = GUICtrlCreateLabel("Inner Side", 494, 338, 64, 20) GUICtrlSetFont(-1, 10, 400, 4, "MS Sans Serif") GUICtrlSetColor(-1, 0x0000FF) $Label6 = GUICtrlCreateLabel(" Select Below For Smith Point Beach Top Sites !", 288, 280, 317, 21) GUICtrlSetFont(-1, 10, 400, 0, "MV Boli") $Label7 = GUICtrlCreateLabel("These Sites Are For SmithPoint Camping Only", 321, 313, 232, 17) GUICtrlSetFont(-1, 8, 400, 4, "MS Sans Serif") $MonthCal1 = GUICtrlCreateMonthCal("2021/03/03", 16, 184, 229, 196) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Combo1 If GUICtrlRead($combo1) = ("Smith Point") Then GUICtrlSetState ($Checkbox1, $GUI_ENABLE) GUICtrlSetState($Checkbox2, $GUI_ENABLE) GUICtrlSetState($Checkbox3, $GUI_ENABLE) GUICtrlSetState($Checkbox4, $GUI_ENABLE) GUICtrlSetState($Checkbox5, $GUI_ENABLE) GUICtrlSetState($Checkbox6, $GUI_ENABLE) GUICtrlSetState($Checkbox7, $GUI_ENABLE) GUICtrlSetState($Checkbox8, $GUI_ENABLE) GUICtrlSetState($Checkbox9, $GUI_ENABLE) GUICtrlSetState($Checkbox10, $GUI_ENABLE) GUICtrlSetState($Checkbox11, $GUI_ENABLE) GUICtrlSetState($Checkbox12, $GUI_ENABLE) GUICtrlSetState($Checkbox13, $GUI_ENABLE) GUICtrlSetState($Checkbox14, $GUI_ENABLE) GUICtrlSetState($Checkbox15, $GUI_ENABLE) GUICtrlSetState($Checkbox16, $GUI_ENABLE) GUICtrlSetState($Checkbox17, $GUI_ENABLE) GUICtrlSetState($Checkbox18, $GUI_ENABLE) Else GUICtrlSetState($Checkbox1, $GUI_DISABLE) GUICtrlSetState($Checkbox2, $GUI_DISABLE) GUICtrlSetState($Checkbox3, $GUI_DISABLE) GUICtrlSetState($Checkbox4, $GUI_DISABLE) GUICtrlSetState($Checkbox5, $GUI_DISABLE) GUICtrlSetState($Checkbox6, $GUI_DISABLE) GUICtrlSetState($Checkbox7, $GUI_DISABLE) GUICtrlSetState($Checkbox8, $GUI_DISABLE) GUICtrlSetState($Checkbox9, $GUI_DISABLE) GUICtrlSetState($Checkbox10, $GUI_DISABLE) GUICtrlSetState($Checkbox11, $GUI_DISABLE) GUICtrlSetState($Checkbox12, $GUI_DISABLE) GUICtrlSetState($Checkbox13, $GUI_DISABLE) GUICtrlSetState($Checkbox14, $GUI_DISABLE) GUICtrlSetState($Checkbox15, $GUI_DISABLE) GUICtrlSetState($Checkbox16, $GUI_DISABLE) GUICtrlSetState($Checkbox17, $GUI_DISABLE) GUICtrlSetState($Checkbox18, $GUI_DISABLE) EndIf Case $Submit sleep (1000) $Date2 = GUICtrlRead ($Day) $Date1 = GUICtrlRead ($Month) $Date3 = GUICtrlRead ($Year) $location = GUICtrlRead ($Combo1) $hookup = GUICtrlRead ($hookups) $nights = GUICtrlRead ($Number_of_Nights) GUICtrlSetData($Day, "01|02|03|04|05|06|07|08|09|10|11|12|13|14|15|16|17|18|19|20|21|22|23|24|25|26|27|28|29|30") GUICtrlSetData($Month,"01|02|03|04|05|06|07|08|09|10|11|12|") Call ("Example") EndSwitch WEnd Example() Func Example() Local $sCompare = 'data-icon-primary="ui-icon-plusthick"' ; Get page 1 Local $dData = InetRead("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD) Local $sData = BinaryToString($dData) ;ConsoleWrite ($sData & @CRLF) Local $aPage = StringRegExp($sData, '<option value="(\d+)', 3) ;_ArrayDisplay($aPage) Local $nPage = $aPage[UBound($aPage) - 1] Local $aTotal = StringRegExp($sData, '(?s)data-icon-primary="ui-icon-plusthick".*?data-title="Site\/Item #"[^\d]+(\d+)', 3) Local $iTotal = UBound($aTotal) Local $aPart ; loop thru all pages using $i as page indicator For $i = 2 To $nPage $dData = InetRead("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=" & $i & "&gotopagenow=yes&gotopage=&module=RN&multiselectlist_value=", $INET_FORCERELOAD) $sData = BinaryToString($dData) $aPart = StringRegExp($sData, '(?s)data-icon-primary="ui-icon-plusthick".*?data-title="Site\/Item #"[^\d]+(\d+)', 3) $iTotal += UBound($aPart) _ArrayConcatenate($aTotal, $aPart) Next Return SetExtended($iTotal, $aTotal) $sData = BinaryToString($dData) StringReplace($sData, $sCompare, $sCompare) $iTotal += @extended $verify = MsgBox(4, $itotal & " Sites Available", "There Are " & $iTotal & " Sites Available at " & $location & " with " & $hookup & ". " & @CRLF & @CRLF & " Do you want to continue to the reservation page?") Select Case $verify = 6 ; YES, proceed with step 1 _IECreate("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD) Case $verify = 7 ; NO thanks EndSelect EndFunc ;==>Example
JayT Posted September 29, 2021 Author Posted September 29, 2021 here is what I have. Doesn't seem to like it? ShellExecute("chrome.exe","https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD)
Subz Posted September 29, 2021 Posted September 29, 2021 You have to remove the ", $INET_FORCELOAD" from the end of the string
AlessandroAvolio Posted September 29, 2021 Posted September 29, 2021 "$INET_FORCERELOAD" comes from InetGet function (https://www.autoitscript.com/autoit3/docs/functions/InetGet.htm 3rd parameter). Third parameter of ShellExecute function is "workingdir" (string type).
JayT Posted September 29, 2021 Author Posted September 29, 2021 This is all it enters in the url? doesn't complete all the variables? https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.htmlAction=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=03%2F06%2F2022&nights=4&category=Smith
Subz Posted September 29, 2021 Posted September 29, 2021 Can you post the full url or test the full url manually with ShellExecute if it fails try using Run(@Comspec & '/c chrome.exe "full url"')
JayT Posted September 29, 2021 Author Posted September 29, 2021 here is the full url request. but for some reason this does not work in IE anymore. _IECreate("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD)
JayT Posted September 29, 2021 Author Posted September 29, 2021 (edited) Does anyone know how I can open chrome with variables in the url? for example i need to open a website with the following however the URL stops at $location and does not fill in the rest. _IECREATE used to work but not anymore and not sure why that is?? any help would be appreciated. Thanks! ShellExecute("chrome.exe","https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", Edited September 29, 2021 by JayT
Solution Werty Posted September 29, 2021 Solution Posted September 29, 2021 Post a working URL without the variables, so we can see what it should look like. Some guy's script + some other guy's script = my script!
AlessandroAvolio Posted September 30, 2021 Posted September 30, 2021 21 hours ago, tedesco said: Does anyone know how I can open chrome with variables in the url? for example i need to open a website with the following however the URL stops at $location and does not fill in the rest. _IECREATE used to work but not anymore and not sure why that is?? any help would be appreciated. Thanks! ShellExecute("chrome.exe","https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", You should open a new thread... Main() Func Main() Local Const $date1 = "1" Local Const $Date2 = "2" Local Const $Date3 = "3" Local Const $nights = "4" Local Const $location = "5" Local Const $hookup = "6" ShellExecute("chrome.exe","http:\\www.google.it\search?q=" & $date1 & "and" & $Date2 & "and" & $Date3 & "and" & $nights & "and" & $location & "and" & $hookup & "end") EndFunc It works fine from me.
JayT Posted September 30, 2021 Author Posted September 30, 2021 Any help at all? I still can't figure this out. Much appreciated!
Moderators Melba23 Posted September 30, 2021 Moderators Posted September 30, 2021 tedesco, Stop posting in multiple threads - you are getting help in this one. Merged. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
Subz Posted September 30, 2021 Posted September 30, 2021 Add the following line above _IECreate and run in Scite, please post the results here, we can then test directly in a browser or via command line. ConsoleWrite("https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=" & @CRLF)
JayT Posted October 13, 2021 Author Posted October 13, 2021 Thank you for the response!! The results are the same. it will bring me to the website but it does not return the results. However, if I copy the url that it pasted in IE and paste it into chrome it works fine.
JayT Posted December 18, 2021 Author Posted December 18, 2021 On 9/29/2021 at 5:58 PM, Werty said: Post a working URL without the variables, so we can see what it should look like. This is what the correct URL looks like when working https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&primarycode=&begindate=06%2F16%2F2022&nights=4&category=Smith+Point&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&keywordoption=Match+One&features1=&features2=&features3=&features4=&features5=&features6=&features7=&features8=&features=&display=Detail&module=RN&multiselectlist_value=&rnwebsearch_buttonsearch=yes" this is what the program is putting out "https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=06%2F16%2F2022&nights=4&category=Smith IDK why it is cutting off the end of the url?
bobomb Posted December 18, 2021 Posted December 18, 2021 (edited) Its probably impossible for us to figure out without the code you are using at the moment.. is this the same as posted before or have you made changes? Is it the above suggested code? Are you using double quotes? '"StringGoesHere"' AutoIT can use a + sign inside a single set of ' ' or " " as a quantifier, and it looks like thats where your address is getting cutoff.. instead of worrying about an escape char you can probably just use single/double quotes.. Of course, without the actual command you are running this is all a guess.. It can also be cmd flags causing the + to be misinterpreted.. etc Edited December 18, 2021 by bobomb
JayT Posted December 18, 2021 Author Posted December 18, 2021 59 minutes ago, bobomb said: Its probably impossible for us to figure out without the code you are using at the moment.. is this the same as posted before or have you made changes? Is it the above suggested code? Are you using double quotes? '"StringGoesHere"' AutoIT can use a + sign inside a single set of ' ' or " " as a quantifier, and it looks like thats where your address is getting cutoff.. instead of worrying about an escape char you can probably just use single/double quotes.. Of course, without the actual command you are running this is all a guess.. It can also be cmd flags causing the + to be misinterpreted.. etc here is the code I am trying to execute. The full URL will work in IE however the page will not load anymore for some reason not sure why so I decided to use Chrome and when I do the full URL will not paste? ShellExecute("chrome.exe","https://parks.suffolkcountyny.gov/wbwsc/webtrac.wsc/search.html?Action=Start&SubAction=&rnwebsearch_search=Yes&primarycode=&begindate=" & $date1 & "%2F" & $Date2 & "%2F" & $Date3 & "&nights=" & $nights & "&category=" & $location & "&subtype=" & $hookup & "&type=FamilySite&begintime=12%3A00+am&endtime=12%3A00+am&quantity=1&keyword=&display=Listing&search=yes&page=&gotopagenow=&gotopage=1&module=RN&multiselectlist_value=", $INET_FORCERELOAD)
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