Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Is there a way to force send a string into an input window?

Author
Message
YoshiDoshi
14
Years of Service
User Offline
Joined: 11th May 2012
Location:
Posted: 28th May 2012 23:57
I was wondering if dbpro had something like Keyboard.SendKeys
so that I can send a string to a currently open program. Does it? Or is there a way to do it?

Thanks

Cheese
Section 812
18
Years of Service
User Offline
Joined: 24th Feb 2008
Location:
Posted: 29th May 2012 06:53
I don't think it can be done with DBPro, mabe with AHK
TheComet
18
Years of Service
User Offline
Joined: 18th Oct 2007
Location: I`m under ur bridge eating ur goatz.
Posted: 29th May 2012 10:34
Quote: "Or is there a way to do it?"


If you're talking about communication between two DBP applications, then there are a few possibilities you could consider.

1) Use the clipboard
2) Use a networking plugin (multisync)
3) Use the hard drive (LOL, no don't really)
4) Post cards (don't foget the stamp)

TheComet

Kezzla
17
Years of Service
User Offline
Joined: 21st Aug 2008
Location: Where beer does flow and men chunder
Posted: 29th May 2012 11:36
you could also try matrix1 plugins peek and poke commands. if you have written both programs that is.

Sometimes I like to use words out of contents
MrValentine
AGK Backer
15
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 30th May 2012 00:12
or try STYX

Diggsey
20
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 30th May 2012 01:12
Quote: "you could also try matrix1 plugins peek and poke commands. if you have written both programs that is."


No, each process has its own address space. You would have to create some shared memory with the bank commands first.

[b]
Red Eye
17
Years of Service
User Offline
Joined: 15th Oct 2008
Location:
Posted: 30th May 2012 04:21 Edited at: 30th May 2012 04:22
Uhmm, I don't use DBP but this is possible: you could query the user32.dll (WinAPI), for FindWindow and then change the text with SetWindowText . Instead of an external Console Application, you would need an actual Windows Application (MSN forexample (cool to have an auto 'hi, how are you?' responder)).

Cheers,

WLGfx
18
Years of Service
User Offline
Joined: 1st Nov 2007
Location: NW United Kingdom
Posted: 30th May 2012 07:30
WinApi has SendInput() or you could also use SendMessage(KEY_DOWN) to a HWND, as well as another one or two more methods.

Mental arithmetic? Me? (That's for computers) I can't subtract a fart from a plate of beans!
Warning! May contain Nuts!

Login to post a reply

Server time is: 2026-07-08 05:37:30
Your offset time is: 2026-07-08 05:37:30