SENDMESSAGE Command with parameters

English support forum

Moderators: Stefan2, white, sheep, Hacker

Post Reply
Hurdet
Senior Member
Senior Member
Posts: 432
Joined: 2003-05-10, 18:02 UTC

SENDMESSAGE Command with parameters

Post by *Hurdet » 2019-06-15, 13:18 UTC

I would like a Commands with parameters SENDMESSAGE POSTMESSAGE to send msg to windows a class.
A simple _WM_COPYDATA send with: Class, String, dwData parameters.

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 37495
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: SENDMESSAGE Command with parameters

Post by *ghisler(Author) » 2019-06-17, 13:58 UTC

You can use AutoHotkey to do this easily.
Author of Total Commander
http://www.ghisler.com

Hurdet
Senior Member
Senior Member
Posts: 432
Joined: 2003-05-10, 18:02 UTC

Re: SENDMESSAGE Command with parameters

Post by *Hurdet » 2019-06-17, 14:31 UTC

yes but I'd rather do it directly without using third-party applications.
it should require little code to get it.

User avatar
MVV
Power Member
Power Member
Posts: 8287
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: SENDMESSAGE Command with parameters

Post by *MVV » 2019-06-18, 12:37 UTC

Well, WM_COPYDATA is not such as easy, it sends a structure pointing to arbitrary data, even standard TC cd command uses binary data, so you can't just use text command line for that w/o some endcoding... Why do you need to send WM_COPYDATA and to which window?

You can use my tiny TCFS2 tool, it allows sending messages to TC windows and searching windows by text or class. However it only allows sending WM_COPYDATA for changing TC directories (tcd command).

Post Reply