Jump to content

Sending Text to a hidden window?


Recommended Posts

Hello, I'm trying to send text to a minimized/hidden notepad. Is this possible?

I don't have much done, but I don't know where to really go from here:

WinWaitActive("note.txt - Notepad","")
Sleep(2000)
WinSetState ( "note.txt - Notepad", "", @SW_HIDE)

Is it possible to use the Send command but maybe have it send to a non active window?

Many thanks for any help,

Nino

Link to comment
Share on other sites

#include <GUIConstants.au3>

opt('MustDeclareVars', 1)
Dim $s_Text = "This is a test"

Run("Notepad")
WinWaitActive("Untitled - Notepad")
Sleep(2000)
WinSetState ( "Untitled - Notepad", "", @SW_HIDE)
Sleep ( 1000 )
ControlSetText("Untitled - Notepad","", "Edit1", $s_Text)
Sleep ( 1000 )
WinSetState ( "Untitled - Notepad", "", @SW_SHOW)

Edited by gafrost

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

Ya, I figured that part out but now i'm working on doing it for a game - World of Warcraft. But the only problem is that when I try and find a Control ID/Class name, nothing shows up, that whole portion is empty. I thought I could also find it by doing a CTRL+ALT+DELETE and finding the Control ID through the list of processes, but that value didn't work. Any ideas?

Link to comment
Share on other sites

It always seems like everyone and their brother is trying to make a bot for that game. DO a search for WOW, and you should find everything you need.

I can't see whats so good about it.... Mind you I haven't tried it so I cant talk.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...