How can i check gave directory is wright or not?in browse input.
[ autoit ]
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <process.au3> $COMPANY_NAME = "HM-LINK" ; name of the pppoe icon, friendly description $SERVICE_NAME = "HM" ; name of the pppoe service configured in NAS/Mikrotik Local $font $DELAY = 300 $frmInformation = GUICreate($COMPANY_NAME, 287, 230, 193, 115) $btnOK = GUICtrlCreateButton("&GO!", 208, 200, 68, 25, 0) $btnbrw = GUICtrlCreateButton("&Browse", 208, 164, 68, 25, 0) $txtbrw = GUICtrlCreateInput("", 118, 164, 80, 21) $lblbrw = GUICtrlCreateLabel("Select Icon:", 16, 169, 80, 17) GUISetState(@SW_SHOW) While 1 $uMsg = GUIGetMsg() Switch $uMsg Case $btnbrw Local $message = "Hold down Ctrl or Shift to choose multiple files." Local $var = FileOpenDialog($message, @WindowsDir & "\", "Icon (*.Ico;*.bmp)", 1 + 4) If @error Then MsgBox(0, "", "No Icon chosen") Else $var = StringReplace($var, "|", @CRLF) EndIf ControlSetText($COMPANY_NAME,"","[CLASS:Edit; ID:11]",$var) Case $btnOK $txtbrwr = GUICtrlRead($txtbrw) If StringLen($txtbrwr)=0 Then MsgBox(64,$COMPANY_NAME &" 03216592390","Please Choose Hm5 Icon.") Else $txtbrwr = GUICtrlRead($txtbrw) ExitLoop EndIf Case $GUI_EVENT_CLOSE Exit EndSwitch WEnd GUISetState(@SW_HIDE) Run("control ncpa.cpl") Sleep($DELAY) WinClose("Network Connections")