Jump to content

MagnumXL

Active Members
  • Posts

    81
  • Joined

  • Last visited

Recent Profile Visitors

473 profile views

MagnumXL's Achievements

  1. Years ago, I made a program with Autoit3 to turn off the monitors of any PC I was connected to remotely, Autoit3 can turn off any one or more monitors on a PC natively with no third-party solution needed although, if I recall correctly, it will need to be run as administrator. I recommend this post to get started.
  2. "\?" will match your single question mark. To remove the it and the rest I would use something like "\?[^\n]+" which technically will remove only the rest of that line but not the return character at the end. Or "\?.*" which remove the ? and all characters after it, including new lines.
  3. I am by no means an expert in this arena but I looked over my code and I did notice a couple of things: I think you are on the right track with your last post. Setting the buttons as gui's themselves. But you won't be able to use GUICtrlSetOnEvent like that. Use GUIRegisterMsg to get the click from a gui. I noticed that I used png's for my button images not bmps. Maybe this is the issue? And on a side note: consider using _GDIPlus_ImageGetWidth/Height just once for each image and then using the variable it returns. That part of your code works but could be more efficient.
  4. It might already be telling you the coordinates to click at. See the "-427px" and "-48px" and the "width: 20px" and "height: 16px". Attempt clicking at -417, -40. If that fails perhaps try appending the url that starts with "images/" to the base url and navigate to that.
  5. Consider using ShellExecute. Or test out using the /b switch (more info) with the run/start command.
  6. If I understand the OP's question... You could to this: Write a script that blocks using BlockInput() and Sleep(). Compile it. Open Task Scheduler (taskschd.msc /s) on your computer Make a new task to run as the system account. Set the action to run your compiled blocking script Set the trigger to be the logon of any user. Test for effectiveness.
  7. As I understand it I think the question your wanting the answer to is "How do I move files, that I only have the name of, using only the mouse?" That is awkward, but if I had the same problem I would: DirCreate() a folder Open it on the desktop with ShellExecute("Explorer", "Path to Folder") WinMove() the folder to an known position (like 0,0) Then FileCopy() the file by name into the new folder Then MouseClickDrag() the file from where it appears in that folder to your chrome browser Then FileDelete() the file from the new folder Repeat Since the file will always appear in the same place this should work.
  8. Here is some script that will retrieve the list of USB storage devices. Just GUICtrlSetData to set the list to your dropdown. #include <AutoItConstants.au3> #include <Array.au3> Local $usbList = "" $aRemDrives = DriveGetDrive("ALL") If IsArray($aRemDrives) Then For $i = 1 To $aRemDrives[0] $driveType = DriveGetType($aRemDrives[$i], 3) If StringInStr($driveType, "USB") Then $usbList &= $aRemDrives[$i] & "|" Next EndIf If $usbList <> "" Then While StringRight($usbList, 1) = "|" $usbList = StringTrimRight($usbList, 1) WEnd MsgBox(0, "USB List" , $usbList) Else MsgBox(0, "Warning", "No USB Drives found.") EndIf Note that using DriveGetDrive("ALL") is important as not all USB devices show up as removable.
  9. Try WinWaitActive("[CLASS:#32770]","Data calculated successfully")
  10. Try ControlGetText first, if that doesn't work MouseDown and MouseUp should do what you are wanting.
  11. In the string provided, "Xx" there is only one unique character. Try using StringInStr or StringRegExp to match by case as well.
  12. I would think that the problem with both this and any inetget script is the link address in the first line. Are you going for apostrophes with the %27's? And of course the whole thing will fail if local (any) DNS isn't handling the "prod" cname.
  13. If it's pictures you want to display without extracting to a directory... I can point you in the right direction. Firstly this page to imbed your pics without installing them at compile and then look at how UEZ uses it on that page. Specifically the _GDIPlus_BitmapCreateFromMemory function in the example. Anything having to do with GDI I look up posts by vip user UEZ he is very knowledgeable in that and many other areas.
  14. Thank you willichan! Great UDF! I did run into one problem. Conditions were as follows: Windows 10 64bit An uninstalled 32bit copy of HyCam2 v.2.29.1.0 Running the example script and udf from the same directory as the HyCam2 binary. After running "HyCam2 -regonly" from an Administrative command promt. Problem: The location of the HyCam2.exe is not recorded in the registry in either of the places the script looks for it. I made the following work around that worked for me and should work on most machines but admittedly could be better: Func __HyCam2_ExePath() Local $regquery = Run(@ComSpec & " /c " & 'REG QUERY HKLM\SOFTWARE /s /f "*\HyCam2.exe"', "", @SW_HIDE, $STDOUT_CHILD) ProcessWaitClose($regquery) Local $sOutput = StdoutRead($regquery) Local $place = "" $place = StringInStr($sOutput, "\HyCam2.exe") If $place Then $sOutput = StringTrimRight($sOutput, StringLen($sOutput) - ($place + 10)) Local $tabPlace = "" $tabPlace = StringInStr($sOutput, " ", 0, -1) If $tabPlace Then $sOutput = StringTrimLeft($sOutput, $tabPlace + 3) If FileExists($sOutput) Then ConsoleWrite(@CRLF & $regquery & " FILE EXISTS! SUCCESS") Return $sOutput EndIf EndIf EndIf Return False EndFunc Note: this does require a few seconds to run. Main thing is, great UDF, it's going to help me out alot! Thank again!
  15. This often happens if code is copied and pasted from Word or a similar program. It automatically changes double and single quotes to those damned opening and closing quotes that are not the same character at all. Whoever that that was a good idea was.. well... wrong.
×
×
  • Create New...