magmet00

searching for working imagesearch and i cant handle a d3dwindow

10 posts in this topic

#1 ·  Posted

Do you have a working imagesearch.au3 with working dll?

and how can i gethandle and send keyboard/mouse commands to hidden d3d window?

 

i have tried imagesearch2015 but im getting dll error every time and tried older imagesearchs too in forum what i found.

i have tried many things to send commands to hidden/background d3dwindow still nothing works.

Can you help me please?

 

Share this post


Link to post
Share on other sites



#2 ·  Posted

What game? Might get better results.

Share this post


Link to post
Share on other sites

#3 ·  Posted

Its not about game. all these topics for notepad everything works on notepad. Really noone sharing a working udf or something for a d3dwindow handle

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

Maybe because no one is using a d3dwindow handle (my only knowledge of it is some obscure Logitech software). How about you provide less a little more information about the application you're trying to automate, rather than expecting everyone to simply guess at what you want?

Edited by JLogan3o13

√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Its a bin file and window class is d3d, just cant handle window. I can active it select window or simple things with just window tittle. Maybe need PID or something? I want  ideas

and im looking for an imagesearch too im getting dllcall error. How can i fix it?

Made many things with pixel search but pixelsearch not enough for all

 

 

Edited by magmet00

Share this post


Link to post
Share on other sites

#6 ·  Posted

Again, you're not providing the code you're using. So you're asking us to first guess at what you're doing and then troubleshoot for you. What is returned when you hover over the window with the Window Info Tool? Show the results


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

$hwindow = WinGetHandle($title)

KeySend($hwindow,0x58)
SimulKey($hwindow, 0x58, 0, "skip", 100)

ControlClick($hwindow, "", "[CLASS:D3D Window]", "right", "1", 606, 499)

ControlSend($hwindow, "", "[CLASS:D3D Window]", "x")

 

and other 

Func _Send_Virtual_Key($iCode)
    If Not IsInt($iCode) Then Return
    DllCall('user32.dll', 'int', 'keybd_event', 'int', $iCode, 'int', 0, 'int', 0, 'ptr', 0)
    DllCall('user32.dll', 'int', 'keybd_event', 'int', $iCode, 'int', 0, 'int', 2, 'ptr', 0)
EndFunc

imagesearch.zip

keytextsend.au3

simulekeys.au3

clickdrag.au3

Edited by magmet00

Share this post


Link to post
Share on other sites

#8 ·  Posted

Well, as you are purposely not answering the questions posed, it becomes apparent you do not want any real assistance. Good luck on your endeavors :)

 


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

I made many codes cant share all because its working fine.

As i said imagesearch not works.. firtly searching for a solution for it

Just a simple part of them:

Func ash()
    sleep(300)
    $CoordAsh1 = PixelSearch(290, 55, 360, 90, 0x47B373)
    $CoordAsh2 = PixelSearch(310, 55, 400, 70, 0xB8B9B3)
    $CoordAsh3 = PixelSearch(255, 55, 355, 90, 0x292031)
    If IsArray($CoordAsh1) = True and IsArray($CoordAsh2) = True and IsArray($CoordAsh3) = True Then
          SetLog("Found the ash", $COLOR_RED)
          $searchsrcount = 0
          try1()
     Else
          sleep(100)
          SetLog("Cant find ash", $COLOR_RED)
          send("{tab}")
          sleep(100)
          $searchsrcount = $searchsrcount + 1
          sleep(150)
    EndIf
     If $searchsrcount > 15 Then
        SoundSetWaveVolume(100)
        Beep(500, 1000)
     EndIf
EndFunc

Edited by magmet00

Share this post


Link to post
Share on other sites

#10 ·  Posted

11 minutes ago, magmet00 said:

I made many codes cant share all because its working fine.

As you seem to avoid answering the question, I can only assume this is game related and as such close the topic.
PM me with prove I am wrong and I will open it again for you.

Either way: Ensure you fully understand  our forum rules before continuing. 

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

  • Similar Content

    • rawkhopper
      By rawkhopper
      Hello everyone,
      I have a script that is automating a piece of sluggish software.  I want to automate it with a bit of caution and I am not sure the best way to do it.  ControlSend works great most of the time.  If I have it enter 10 into a text box every once in a while it will enter 1 or 11 and then hit enter.
      To overcome this I use MouseClick to select the text I just entered and then see if it matches the string it was supposed to put in before it hits enter.  This seems to work but what I love about ControlSend is there is less room for human interaction messing it up.  
      Yes I could block input but I prefer not to do that (permissions).
      Is there a better way of doing this?  Any Help would be much appreciated.
      Anyway here is the snippet of the script in question:
      Func KVSend () WinActivate ( "Window", "" ) Local $WindowPos = WinGetPos("Window", "") If $kV < 30 Then WinActivate ( "Window", "" ) ControlClick ("Window", "", 1001) ;Click in Accel Voltage box Sleep (100) ControlSend ("Window", "", 1001, $kV) ; \ kV Sleep (100) MouseMove($WindowPos[0]+130,$WindowPos[1]+75,1) MouseClick($MOUSE_CLICK_LEFT) MouseClick($MOUSE_CLICK_LEFT) Send ("^c") Local $clip = ClipGet () If $clip = $kV Then ControlSend ("Window", "", 1001, "{ENTER}") ;Hit ENTER if value is correct Sleep (100) ControlClick ("Window", "", 1518) ;Lens Clear Else Send ("{BACKSPACE}") KVSend() ; If value is incorrect try again EndIf EndIf  
    • Guy_
      By Guy_
      Was testing ControlSend("My Window Name", "", "", "^c") vs the normal Send("^c") or _SendEx("^c") to copy selected text from a window...
      In Windows, I have a setting that when I click the Ctrl key only, my mouse pointer is "highlighted" [that I could of course disable].
      If I use Send("^c"), or do this manually, the mouse pointer is never highlighted, as I wish it to be.
      With ControlSend it *does* highlight...
      I thought that maybe the Ctrl key goes up a few ms too soon in that one and increased AutoItSetOption("SendKeyDownDelay", 5) to way higher, but it doesn't make a difference.
      As it doesn't seem possible to do "^ down", could it be prevented in some way?
      Beside the slight annoyance, it simply alerted me that these seem to work differently [and of course, they are different].
      I also get the early impression that ControlSend [to copy] seems in no way quicker to get something on the clipboard, maybe even slower?
      Thanks 
    • SkysLastChance
      By SkysLastChance
      How would I go about writing a IF Then statement if the conrol send fails?
      Run ("Notepad.exe") WinWaitActive ("Untitled - Notepad") ControlSend("Untitled - Notepad", "", "Edit1", ("Provider Practice Record")) I have been running into lag alot. So my script has been missing input. I would like to be able to have it retry to put in "Provider Practice Record" if it misses. 
      I am assuming  a if then statement is what I need but I am not sure what ControlSend will return if it tries to send to Edit1 and it is not there. 
      Or do I need to just add a timeout? 
       
    • knuxfighter
      By knuxfighter
      Hello. I've been working with Imagesearch library lately and it did a good work, although I moved to a new PC and didn't copy the old files with me so I downloaded the Imagesearch from the following post
       hoping that it will work. It doesn't though. First time I when I use (run as subscript to my code) the Imagesearch.au3, Scite finds errors (missing spaces). Ctrl+T (scite tidy) fixes these missing spaces but the script returns the following error on every run after:
      _ImageSearch('search.bmp', 0, $x, $y, 0) outputs
       
      "C:\Users\Knuckles\Desktop\AutoIt\include\ImageSearch.au3" (44) : ==> Subscript used on non-accessible variable.: If $result[0] = "0" Then Return 0 If $result^ ERROR no matter if I put the searched bmp in the script folder or folder img in the script directory. Also, it doesn't matter if the searched image on screen or not, it returns the same.

      Can you provide me any help please? I remember having these problems 2 years ago when I first met the imagesearch library also (I fixed it somehow though in that time). Seems nothing changed.

      Using this version posted in the following post gives the same error:
      Also I run windows 10 64bit and I have no shell options for script editing, running as x86 or whatever as I used to have on windows xp/7. I went through some steps like deleting a key in registry and I even reinstalled autoit and scite but that only resulted to au3 as unrecognized file format and not in getting back the menus and the icon on au3 files. Any thoughts on this?

      Edit: Installing 64-bit AutoIt and using 64bit ImageSearch is no change.
      code.au3

      FOUND WORKING: http://www.codebot.de/index.php/Thread/12713-Imagesearch-au3-funktioniert-nicht/
       but why is this one working and the original aren't? :(
    • SkysLastChance
      By SkysLastChance
      Okay so I am not sure if I can do this or not with the code I currently have but, I would like to send lastname and the first name with a comma inbetween. 
      so it would look like "last name,first name" 
      right now I just have it sending the last name.
      any help or sugestions are appreciated. 
       
      $r = 1 Local $aArray = _Excel_RangeRead($oExcel, Default, Default) For $i = 1 To UBound($aArray) - 1 ;$i =0 Start from row A $sR1 = $aArray[$i][0] ;status $sR2 = $aArray[$i][1] ;first name $sR3 = $aArray[$i][2] ;Last name $sR5 = $aArray[$i][5] ;Email Address WinWaitActive ("[CLASS:MGUIWin]") Sleep (100) ControlSend("[CLASS:MGUIWin]", "", "Edit2", $sR3, & @CR) $r = $r + 1 If $r > $sBox Then Exit Endif Next