I have written a small Windows program called SendCB which simply sends the contents of the clipboard as a sequence of keystrokes to a specified application window. I would like to be able to use it from TextPad to send the current selection to the specified window. To this end, I add SendCB as a tool to the Tools menu and assign it an accelerator key (F10, say). So far so good - I can select some text, copy it to the clipboard, hit F10 and bingo, the text appears in the window of my specified app.
To automate this, I then try to record a macro that (1) copies the current selection to the clipboard and then (2) invokes the SendCB tool via the F10 key. The macro recording appears to go ok. To test it, I select some text, play the macro and... zilch, nada, nothing happens. At this point I RTFM and find that Tools (and accelerator keys in general?) cannot be recorded... any alternative ideas as to how I might get this to work?
Tool/Macro problem
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
Tool/Macro problem
Lionel B
Maybe you can change your program so that it sends a Ctrl+C keystroke to the active window first? Or have it accept a command line parameter, and add $sel to your tool definition.
And I'm sure that someone will soon mention MacroScheduler as a solution. I haven't used it myself, but apparantly it can be used to automate such tasks as you describe.
HTH, Berend
And I'm sure that someone will soon mention MacroScheduler as a solution. I haven't used it myself, but apparantly it can be used to automate such tasks as you describe.
HTH, Berend
- Bob Hansen
- Posts: 1516
- Joined: Sun Mar 02, 2003 8:15 pm
- Location: Salem, NH
- Contact:
I'll do that for you:someone will soon mention MacroScheduler
I can strongly recommend that uou use Macro Scheduler for that and many more tasks.
Also has a syntax file for use with TextPad.
Hope this was helpful.............good luck,
Bob
Bob
Thanks, turns out that $Clip does the job nicely.Maybe you can change your program so that it sends a Ctrl+C keystroke to the active window first? Or have it accept a command line parameter, and add $sel to your tool definition.
Hmm, I occasionally use the more free (as in beer) AutoIt3.I can strongly recommend that uou use Macro Scheduler for that and many more tasks.
Regards,
Lionel B
Macro Scheduler
Thanks for the link Bob - Macro Scheduler is priceless
I had never heard of it before ...
I had never heard of it before ...
Charles
http://www.charleswebdesign.com/
http://www.charleswebdesign.com/