caramen Posted October 5, 2018 Share Posted October 5, 2018 (edited) Can i mix 2 winwait with OR statement ? WinWait ("FortiClient") Or WinWait ("SslvpnClient.exe") Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
FrancescoDiMuro Posted October 5, 2018 Share Posted October 5, 2018 @caramen WinWait() returns an handle to the requested window, so, you would going to compare logically two handles... It depends from what you're trying to do caramen 1 Click here to see my signature: Spoiler ALWAYS GOOD TO READ: Forum Rules Forum Etiquette Link to comment Share on other sites More sharing options...
Developers Jos Posted October 5, 2018 Developers Share Posted October 5, 2018 The answer is No, so use WinExists() in a loop and build the logic yourself. Jos FrancescoDiMuro and caramen 1 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. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) The goal is to Run an msi install but if i am not in my domain i got a windows Ssvpnclient.exe After 10 sec timout Since i install the vpn... Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 Ahh yes ok thx My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
jdelaney Posted October 5, 2018 Share Posted October 5, 2018 (edited) Create a loop where you continue until your wait time expires. in the loop, exit if winexist returns true for either window. Edit: slow typing in mobile Edited October 5, 2018 by jdelaney caramen 1 IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 14 minutes ago, jdelaney said: Create a loop where you continue until your wait time expires. in the loop, exit if winexist returns true for either window. As @FrancescoDiMuro said 18 minutes ago, FrancescoDiMuro said: @caramen WinWait() returns an handle to the requested window, so, you would going to compare logically two handles... It depends from what you're trying to do And Unfortunatly ShellExecute ("SslvpnClient.exe","","\\escs006\Utils$\VPN\Client lourd Fortigate\sslvpnclient64") Is same. So i just understood that the problem is differente. @Jos Solution cannot work too. I cant do Winlist or WinExist until i got the error. And i have to click manualy. Maybe an... no hmmm zzZ... your solution was the most easy but.... Since i cant do anything from Autoit. until i click OK on the error msg. I dont know how to do finaly. My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) ShellExecute ("SslvpnClient.exe","","\\*****\****$\VPN\Client lourd Fortigate\sslvpnclient64") Is still controlable with @error or somthing after that ? Ahhhhhhh i can check the ip adress to check the domaine connection. Or vpn connection and all the rest connection. hmmmmmmmmmmmmm More viable ? Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
FrancescoDiMuro Posted October 5, 2018 Share Posted October 5, 2018 (edited) @caramen It is telling you that it couldn't find that application. Try this way: ShellExecute("\\*****\VPN\Client lourd Fortigate\sslvpnclient64\SslvpnClient.exe") Edited October 5, 2018 by FrancescoDiMuro Click here to see my signature: Spoiler ALWAYS GOOD TO READ: Forum Rules Forum Etiquette Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) 10 minutes ago, FrancescoDiMuro said: @caramen It is telling you that it couldn't find that application. Try this way: ShellExecute("\\*****\******$\VPN\Client lourd Fortigate\sslvpnclient64\SslvpnClient.exe") @FrancescoDiMuro No mate hmm how to tell you. The code is working. This error is becoming espected when at home./ But when i am at home I am checking all possible scenario for installation. I want to keep my Shell execute But it s not working at home. i want to dodge this or detect it. Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) I could possibily dodge the installation with IP checks. That's a good viable easy sollution i think no ? Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
jdelaney Posted October 5, 2018 Share Posted October 5, 2018 To install, you probably are running your script as admin which will not share the same drive mappings as your user. IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 I am admin this is not the problem. My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
jdelaney Posted October 5, 2018 Share Posted October 5, 2018 Running elevated is different than running as admin IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) I guess i have to explain more then When you are at work every one got that drive mounted. Every one got right to run this executable everyone is elevated enouth with NTFS to execute that file that IS NOT the problem. I got 3 scenario possible for installation. At work installation will work. On some wifi it will work too at home it wont work since i install the VPN software i cant connect to my intranet drive this is obvius. <<<< This is WHY i got the error. ==== it s non logic but if i install it from my home with vpn connection it will work too but no point to install if already installed. Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
jdelaney Posted October 5, 2018 Share Posted October 5, 2018 Makes sense from home. Sounds like a security flaw at work. Just fyi,a user's drive mappings will not be present when you run the script elevated. But it sounds like anyone that can ping your server can grab the file IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) Well this is how i will proceed. Lucky i got all my vlan in mind. I will check all ip like this. $cVlan = _StringExplode ( @IPAddress1 , "." ) If $cVlan[0] = "My wanted byte" And $cVlan[1] = "My wanted byte 2" Then install () EndIf I got something like 6 check and error checking to add. But if you guys got a way to manage the shellexecut's error i am whould like to take ;p Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - Wiki Link to comment Share on other sites More sharing options...
jdelaney Posted October 5, 2018 Share Posted October 5, 2018 You could alway just do a fileexists too, but to break down exactly what is failing is always helpful in logs caramen 1 IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
caramen Posted October 5, 2018 Author Share Posted October 5, 2018 (edited) 26 minutes ago, jdelaney said: You could alway just do a fileexists too, but to break down exactly what is failing is always helpful in logs Ahhhhh that's an other way yes. Finaly i got what you say. The local checking of mapped drive can proof the presence of the network or not. And even if user have not the rights to use run it. Edited October 5, 2018 by caramen My video tutorials : ( In construction ) || My Discord : https://discord.gg/S9AnwHw How to Ask Help || UIAutomation From Junkew || WebDriver From Danp2 || And Water's UDFs in the Quote Spoiler Water's UDFs:Active Directory (NEW 2018-10-19 - Version 1.4.10.0) - Download - General Help & Support - Example Scripts - WikiOutlookEX (2018-10-31 - Version 1.3.4.1) - Download - General Help & Support - Example Scripts - WikiExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example ScriptsPowerPoint (2017-06-06 - Version 0.0.5.0) - Download - General Help & SupportExcel - Example Scripts - WikiWord - Wiki Tutorials:ADO - 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