All Activity

This stream auto-updates   

  1. Past hour
  2. Slacker, unfortunately that does not work as i cannot control the object using usual methods for some reason that is the whole dilemma. Fortunately InnI has provided a solution for me! - Thank you !!!! will be using this IUIAutomation in the future !!!!!!
  3. Today
  4. Thanks RTFC, yes, helped a lot. I think my problem is a lack of good knowledge on dllstruct and similar ones. I think that when someone opens an huge area like that, probably is to put there arrays and to access individual cells in that array. Your HighMem is very simple to use and seems to be very good for my purpose. Just allocates an area where can, for example, an array. At another process I can get that data. So, I wonder I could "map" an AU3 array at that area. My question about performance was if to read/write a bunch of individual cells in a loop, for example, would be efficient. In other words, use it like a plain array?
  5. Someone here gave me some help in order to detect if my Yubikey is inserted or not, by checking the Windows system for all "keyboard" devices for the presence of the serial number of my Yubikey. Then once unplugged and found to be missing, take some action like lock the PC. The problem is it does not work with the newer Yubikeys because, I think, they act as smartcards or something. So the code looking for a keyboard is no good. There was some kind of tool which I used to help me find what to search for I think, I do not remember. Here is the function which did the original checking, but I am totally clueless on how to tweak it to again be able to find the serial number of my new (no longer acting as a keyboard) Yubikey. Func CheckForYubikey($input) $Output = "" $object = ObjGet("winmgmts:\\" & $strComputer & "\ROOT\CIMV2") $items = $object.ExecQuery("SELECT DeviceID FROM Win32_Keyboard", "WQL", _ $wbemFlagReturnImmediately + $wbemFlagForwardOnly) If IsObj($items) Then For $objItem In $items FileWriteLine('test.txt', $objItem.DeviceID) If StringInStr($objItem.DeviceID, $YubikeySerialNumber) Then Return True Next Else Return False EndIf Return False EndFunc ;==>CheckForYubikey Any help would be appreciated.
  6. Hi Jose. My first impulse was to just refer you to my Eigen4AutoIt environment (v4.1), which contains a working example (test #20 in the EIgenTest subdirectory) of a matrix (struct) being created by one process, an subsequently written two in alternating fashion by a second process and the first (both filling it with their PID). That example illustrates mutex usage as well, as you'll see each process failing to obtain the mutex until the other one releases it (after which a successful write occurs). My second impulse was to refer you to the _WinAPI_CreateFileMapping example in the AutoIt Help, which shows how to share a joint memory allocation between two processes without mutex. But of course, that one doesn't involve the HighMem environment, which takes care of all the nitty gritty of keeping your memory allocations organised. So my third impulse, followed here, is to share two tiny test scripts from my earliest testing phase of _HighMem. Both use a struct as a string buffer for one process to store user-defined text in and the other process to read it back, just like in the CreateFileMapping example (but using the HighMem environment). Obviously, you can stick anything you like into a struct, including an array (e.g., convert to string and store in struct at one end, and do the reverse at the other end). If you need more extensive examples of how to use structs as generic tmporary containers for any type of variable, I would suggest you study my Pool IPC environment (link in my sig below). Start this script first (the HighMem equivalent of the AutoIt Help file example referred to above), but don't fill the inputbox yet... #AutoIt3Wrapper_UseX64=Y #NoTrayIcon #include <MsgBoxConstants.au3> #include <WinAPI.au3> #include <WinAPIFiles.au3> #include "D:\Autoit\HighMem\HighMem.au3" $_HighMem_verbose=True Opt('WinWaitDelay', 0) Global Const $g_sTitle = 'TestHighMem' Global $sText Global $mapobjectname=$_HighMem_NamePrefix & '123' ; fake PID _HighMem_StartUp(1) _HighMem_MapExternalMemory(123, False) ; fake PID Local $sText,$tData = DllStructCreate('wchar[1024]', $_HighMem_ExternalBaseOffset[1]) While WinWait($g_sTitle, '', 1) Sleep(200) $sText = DllStructGetData($tData, 1) DllStructSetData($tData, 1, '') If $sText Then MsgBox(BitOR($MB_ICONINFORMATION, $MB_SYSTEMMODAL), $g_sTitle & " (receiver)", " " & @CRLF & $sText) WEnd _HighMem_CleanUp() Then start the second one below, then type something and press Ok. #AutoIt3Wrapper_UseX64=Y #NoTrayIcon #include <MsgBoxConstants.au3> #include <WinAPI.au3> #include <WinAPIFiles.au3> #include "D:\Autoit\HighMem\HighMem.au3" $_HighMem_verbose=True Opt('WinWaitDelay', 0) Global Const $g_sTitle = 'TestHighMem' Global $sText Global $mapobjectname=$_HighMem_NamePrefix & '123' _HighMem_StartUp(1,"GB",$mapobjectname) Local $sText,$tData = DllStructCreate('wchar[1024]', $_HighMem_BaseOffset) While WinWaitClose($g_sTitle) $sText = StringStripWS(InputBox($g_sTitle & " (sender)", 'Type some text', '', '', -1, 171), 3) If Not $sText Then ExitLoop DllStructSetData($tData, 1, $sText) If Not WinWait($g_sTitle, '', 1) Then ExitLoop WEnd _HighMem_CleanUp() IMPORTANT: this simple example works for a single allocation only, because it maps the struct directly to the shared memory base pointer (the start of the total pre-allocated region). But obviously, only the first allocation has an offset of zero. Any allocation made thereafter by script 1 will have a relative offset larger than zero. So you have to start parsing those offsets to your second (and third, fourth, etc) script(s) using some form of IPC (for example, using my Pool environment ). And the second script then calls _HighMem_AllocateExternal ( $PID, $offset, $size, $unit="B"), after first calling _HighMem_MapExternalMemory( $PID ). Maybe I can provide a nexample of that some other time. I'm not sure by what you mean by "efficient" in this context. Using a shared resource and just communicating a pointer once is certainly less data traffic than moving a 1000x1000 cell array back and forth every time, if that's what you mean. And yes, these allocations can be any size that fits into your virtual memory. Does that clarify things for you?
  7. Attack is the best defense approach? 7 days to think about that last post whether that is the way you want to continue here or not. Jos
  8. Second, dont care about impression. Since I rarely get useful answers on my questions I dont really care whose 'hammer' I will get, not much will change...
  9. This is the second or third time I have seen you posting like this - not sure if you're under the mistaken impression that it's clever or funny. Continue with this and and you can personally experience the hammer.
  10. Gaat prima hoor! Jos
  11. Hi, I have a file with many rows that i want to convert to array. The thing i need is to add a comma and 1 space after end of each line like "first line, second line, third line, fourth line". Document looks like this 277 278 279 281 282 283 590 285 473 476 482 286 287 275 280 284 1059 1063 1067 1083 1071 1055 And here is code i try. #include <File.au3> $file = FileOpen("test.txt", 0) $oFile = FileReadToArray($file) For $i = 1 to UBound($oFile)-1 $line = FileReadLine($file, $oFile[$i]) $replace = $line & ", " ConsoleWrite($replace) Next
  12. @Jos Sorry I meant Another threah but this time without Game automation. My English is not great. Thanks that the thread can stay
  13. Read in Debene QPDF Reference about: DrawHTMLTextBox and try: _QPDF_TXT_to_PDF _QPDF_TXT_to_PDF_Lite _QPDF_TXTFile_to_PDFFile
  14. As @Danp2 said So @domina did you try on another location, at home, at friend ..... ? Of course also on different ISP.
  15. @Golfboy, Funny you now say you create a thread with game automation while you stated before in PM it wasn't about game automation at all. Nikolas92 is right about not re-opening a thread on the same topic in general, but I will let this go as long as it is about general software updates. Jos
  16. Please refrain from these type of comments and simply report when you feel you need to act upon this. thanks. Jos
  17. Sorry, but it's an environmental issue AFAICS and I'm all out of ideas ATM.
  18. You should read the forum rules, particularly this section --
  19. Reboot, no firewall. Also tried tunnel bear. Nothing works. When I change the url to any other site it works without a problem. If the site doesnt exisist it takes more time till the script fails. Only the server makes these problems.
  20. Any firewalls / corporate proxies involved? Have you tried rebooting?
  21. But why.... there is nothing about game automation. I'm just asking how I can improve the code and how I can get the process to the background
  22. Running on a fully patched machine. Also tried a different PC. The script run just fine a week ago. I really can not understand whats wrong.
  23. Hurry change your question more or Yoda the Ban Hammer will lock it again.
  24. I do not get this issue with Windows 10, so it is either a Windows 7 issue or something with your local setup. Is your machine fully patched, including this one?
  25. Iam running windows 7 x64. I can open the site in IE and firefox. Also i made sure that may IP or headder isnt blocked.
  26. My thread got locked, unfrotunately. So here another thread without "game automation". I have been looking for a program that can keep my other programs up to date and I found AutoIt. I have no coding experience. I can just read it a little bit so it was quite hard to actually get something done but after watching a few videos I finally got it working! Especially the zip part was quite hard since I dont understand what I have to do with the "Zip UDF premade concepts" that users provide. At the end I just did it with Mouseclicks. So now the prgram is working as you can see in the video but I would like to do this in the background. It's not really important for this task but I would like to create more with AutoIt since I think the program is fantastic! so my question is: How can I improve my code and get it to the background so I can do other stuff while AutoIt is busy? Here is the video for the code and how it works.
  1. Load more activity