zelles Posted November 21, 2014 Share Posted November 21, 2014 When I use _IECreateEmbedded() to view a folder, the script stops repsponding to the button/events. I can open the program and close it like normal... The thing is if I open the program and click the view button to view the folder, the script no longer acknoledges any button/events and becomes unclosable; even though the folder is viewable in the browser. Anyone know why it's not responding once the folder is opened? Or how I can get it to start responding again once the view button is clicked? #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <GUIListBox.au3> #include <IE.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> Global $UI2_IEObj = _IECreateEmbedded() Global $UI2_ClientBrowser = GUICreate("Browser", 635, 340) Local $UI2_MENU_File = GUICtrlCreateMenu("&File") Global $UI2_MENU_Exit = GUICtrlCreateMenuItem("&Exit", $UI2_MENU_File) Local $UI2_Label1 = GUICtrlCreateLabel("Clients:", 5, 16, 38, 17) Global $UI2_ClientList = GUICtrlCreateList("", 0, 40, 145, 279) Global $UI2_BTN_View = GUICtrlCreateButton("View", 64, 8, 75, 25) Global $UI2_Browser = GUICtrlCreateObj($UI2_IEObj, 144, 0, 489, 319) GUICtrlSetColor($UI2_ClientList, 0x808080) GUICtrlSetBkColor($UI2_ClientList, 0xB9D1EA) GUISetBkColor(0xC0DCC0) GUISetState(@SW_SHOW, $UI2_ClientBrowser) While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit Case $UI2_MENU_Exit Exit Case $UI2_BTN_View Local $f_selected = _GUICtrlListBox_GetCurSel($UI2_ClientList) Local $f_NameFull = _GUICtrlListBox_GetText($UI2_ClientList, $f_selected) _IENavigate($UI2_IEObj, "file:///" & StringReplace(@ScriptDir, "\", "/")) EndSwitch Sleep(10) WEnd Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted November 21, 2014 Moderators Share Posted November 21, 2014 Try: _IENavigate($UI2_IEObj, "file:///" & StringReplace(@ScriptDir, "\", "/"), 0) Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
zelles Posted November 21, 2014 Author Share Posted November 21, 2014 Try: _IENavigate($UI2_IEObj, "file:///" & StringReplace(@ScriptDir, "\", "/"), 0) Thank you so much! That seams to of fixed it. 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