Jump to content

All Activity

This stream auto-updates     

  1. Past hour
  2. @geoffrey6767 We do not permit payware promotions - one would think you could figure this out with all the other promotions that have been immediately removed from this thread.
  3. Alternatively use AdlibRegister for example: #include <ButtonConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #include <GuiConstants.au3> #include <MsgBoxConstants.au3> Global $bPing = False, $iCounter = 0, $Title = "Back Online? v1 by Dan" HotKeySet("{ESC}", "_Terminate") GUICreate($Title,300,200) $sCenter = WinGetClientSize($Title) GUICtrlCreateLabel("Back Online?",0,10, $sCenter[0],50,$SS_CENTER) GUICtrlSetFont (-1,20) GUICtrlCreateLabel("Enter The IP Address To Monitor", 0, 60, $sCenter[0],-1,$SS_CENTER) GUICtrlSetFont (-1,12) Global $sIPAddr = GUICtrlCreateInput("",70, 90, $sCenter[0]/2,30,$ES_CENTER) $sStartPing = GUICtrlCreateButton("Monitor",70,125,$sCenter[0] / 2,25,$SS_CENTER) GUICtrlCreateLabel("Waiting IP...", 120, 175,60) GUISetState(@SW_SHOW) AdlibRegister("_Ping") While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $sStartPing If GUICtrlRead($sIPAddr) == "" Then MsgBox(64,$Title,"Yeet says hi!") GUICtrlSetData($sStartPing, "Monitor") $bPing = False Else GUICtrlSetData($sStartPing, "Monitoring...") $bPing = True EndIf EndSwitch WEnd Func _Ping() If $bPing = False Then Return If Ping(GUICtrlRead($sIPAddr), 50) Then _Success();$ipaddr) Else $iCounter +=1 if $iCounter > 10 Then MsgBox(64,$Title,"I dont think its coming back?"&@CRLF&"Ill Close") ; use ie_create http://localhost/backon.php?status=Offline&ip=$ipaddr Exit EndIf GUICtrlSetData(-1,"Attempt "&$iCounter) EndIf EndFunc Func _Terminate() Exit EndFunc Func _Success() MsgBox(64,$Title,"Its back up,"&@CRLF&"Ive sent you a notification") ; use ie_create http://localhost/backon.php?status=Backup&ip=$ipaddr Exit EndFunc
  4. I like what you are doing even if I haven't need it. But surely is a god-sent when is needed. So thank you for working on it
  5. You're all heroes, truly! Thanks a lot! I got this to work, so I'll build from that example to implement what I need in my code. Thanks, @Danyfirex! And of course, a lot of gratitude as well for @Earthshine and @water and @TheXman for getting this discussion going! 😍
  6. Melba23, I like your UDF a lot - it is very useful to me 😁 I encounter a small issue, maybe you can help me out... If I use a column with auto-drop-down, like to type any other text which is _not_ in the drop down list and press enter the input will be discarded (= blank list view item). If I repeat it works... Here is a reproducer (- please use "Col-3" to test): #include <GUIConstantsEx.au3> #include <MsgBoxConstants.au3> #include "GUIListViewEx.au3" Local $hGUI = GUICreate("TEST", 500, 500) Local $cLV = GUICtrlCreateListView("Col-0|Col-1|Col-2|Col-3", 10, 10, 420, 260, BitOR($LVS_SINGLESEL, $LVS_SHOWSELALWAYS)) _GUICtrlListView_SetExtendedListViewStyle($cLV, $LVS_EX_FULLROWSELECT) For $i = 0 To 3 _GUICtrlListView_SetColumnWidth($cLV, $i, 100) Next Global $aLVArray[6][4] For $i = 0 To 5 $sData = $i & "-0" $aLVArray[$i][0] = $sData For $j = 1 To 3 $sData &= "|" & $j $aLVArray[$i][$j] = "" & $j Next GUICtrlCreateListViewItem($sData, $cLV) Next $iLVIndex = _GUIListViewEx_Init($cLV, $aLVArray) _GUIListViewEx_SetEditStatus($iLVIndex, 3, 2, "||1|2|3|4|5|6", 2) _GUIListViewEx_MsgRegister() GUISetState() While 1 Switch GUIGetMsg() Case $GUI_EVENT_CLOSE Exit EndSwitch _GUIListViewEx_EventMonitor() WEnd I guess it has something to do with the auto-complete behavior... Any change to work around to store the input at the fist time?
  7. Nope, still shows as \\dfsroot\site\RetailApps for the ProviderName.
  8. You might like to use Opt("GUIOnEventMode", 1) GUICtrlSetOnEvent ..... to trap your GUI events and run functions when they are clicked. This frees you from constantly checking for them in a while / case loop. There are some good examples on the GUICtrlSetOnEvent help page. I'm sure there are appropriate use cases for both methods, but I find I always use this method to write GUIs in AutoIt.
  9. yeah, that should do it! i was thinking along those lines after looking at the VBA example
  10. Today
  11. Because the forum changes the content, I can do nothing. Delete the bracket at the end of the line and enter it again. Is it hard to do?
  12. Edited: Browser sent info twice 😤. Saludos
  13. Hello. my two cents... #include <MsgBoxConstants.au3> Global $oErrorHandler = ObjEvent("AutoIt.Error", "_ErrFunc") ;Register AutoIt Error handler Global $oObject = ObjCreate("JustRemotePhone.RemotePhoneService.ApplicationFactory") ;Create Main object ConsoleWrite("-oObject: " & IsObj($oObject) & @CRLF) Global $oApplication = $oObject.CreateApplication("AutoIt Client") ;Create Application If Not IsObj($oApplication) Then Exit MsgBox($MB_ICONERROR, "Error", "Unable to Create 'Remote Phone Call' Instance") EndIf Global $sNumber = InputBox("Add a number to be Called", "Phone Number", "") If Not $sNumber Then Exit MsgBox($MB_ICONINFORMATION, "Error", "Phone Number is Emtpy Script will Exit.") $oApplication.BeginConnect(True) ;Begin Connection ;You probably will need to grant accest to the application at this point. Global $oPhone = $oApplication.Phone ;Create Phone Object ConsoleWrite("-oPhone: " & IsObj($oPhone) & @CRLF) ;Call $oPhone.Call($sNumber) $oApplication.BeginDisconnect() ;End Connection ; User's COM error function. Will be called if COM error occurs Func _ErrFunc($oError) ; Do anything here. ConsoleWrite(@ScriptName & " (" & $oError.scriptline & ") : ==> COM Error intercepted !" & @CRLF & _ @TAB & "err.number is: " & @TAB & @TAB & "0x" & Hex($oError.number) & @CRLF & _ @TAB & "err.windescription:" & @TAB & $oError.windescription & @CRLF & _ @TAB & "err.description is: " & @TAB & $oError.description & @CRLF & _ @TAB & "err.source is: " & @TAB & @TAB & $oError.source & @CRLF & _ @TAB & "err.helpfile is: " & @TAB & $oError.helpfile & @CRLF & _ @TAB & "err.helpcontext is: " & @TAB & $oError.helpcontext & @CRLF & _ @TAB & "err.lastdllerror is: " & @TAB & $oError.lastdllerror & @CRLF & _ @TAB & "err.scriptline is: " & @TAB & $oError.scriptline & @CRLF & _ @TAB & "err.retcode is: " & @TAB & "0x" & Hex($oError.retcode) & @CRLF & @CRLF) EndFunc ;==>_ErrFunc PD: Can't load syntaxhighlighter Cuz My Connection is too slow. So I'll update it later. Saludos
  14. so you can still run and install it. they are just informing you that they can't verify the publisher, and if you want to trust them.
  15. Also look at this Wiki page: https://www.autoitscript.com/wiki/Interrupting_a_running_function
  16. Problem Found BmpSearch.au3" (46) : ==> Variable must be of type "Object".: Local $iRowInc = ($tSizeSource.X - $tSizeFind.X) * 4 Local $iRowInc = ($tSizeSource.X - $tSizeFind^ ERROR BmpSearch downloaded from
  17. In a fresh windows 10, I tried to Dl the studio with that edge thingi MS is so proud of and got this. So it seems that MS don't see the studio as a virus. Cheers /Rex
  18. Yeah, I can connect the ApplicationFactory-object as well, without any issues, but this ApplicationFactory-object is mentioned nowhere in RemotePhone's API. So, I contacted them to see what possibilities there are to get this to work. If I find out more, I'll post it here... Greetings!
  19. I am quite confident (but it remains untested on my part) that some of the Win32_ WMI class could answer your question. Look at Win32_MappedLogicalDisk or Win32_LogicalDisk or some other class in that category. You may find what you need.
  20. @badcoder123 Control changes at every new instance of paint, it needs to be a regexp. Anyway he doesn't want to implement this in Paint, it is for an "In-house apps"...
  21. If so then look at .txt class, it will tell you which one is which.
  22. Yes, provided .txt is associated with name "txtfile" but its "textfile" in some setups...
  23. Just add this key in regedit HKEY_CLASSES_ROOT\txtfile\shell\print\command : REG_EXPAND_SZ %SystemRoot%\system32\NOTEPAD.EXE /p %1
  24. When you go into your _Ping function it's stuck in the While loop. If you want to have the gui close, you need to add in code to read the GUIGetMsg again and action on that or have some way to exit the loop to return to the main message loop.
  1. Load more activity
  • Create New...