Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

macro recorder


  • Please log in to reply
24 replies to this topic
Bruce
  • Members
  • 5 posts
  • Last active: Dec 22 2005 10:08 PM
  • Joined: 21 Dec 2005
Page 1 of this site says:

You can write a mouse or keyboard macro by hand or use the macro recorder.

I read the tutorial, it didn't say anything about the macro recorder.

Help!

Bruce

Serenity
  • Members
  • 1271 posts
  • Last active:
  • Joined: 07 Nov 2004
Look in your AutoHotkey install folder for a folder called AutoScriptWriter - that's the macro recorder.
"Anything worth doing is worth doing slowly." - Mae West
Posted Image

Bruce
  • Members
  • 5 posts
  • Last active: Dec 22 2005 10:08 PM
  • Joined: 21 Dec 2005
Ok, I found it. Is there any documentation on how to use it?

When I clicked it, a window pops up, it has a bunch of buttons (broswe, window text, record macro...)

Back in the good old DOS days there was a product called ProKey, it was SO EASY to use. Hit Alt =, then hit the key you want to program (F4 perhaps), then type away, then when you're done hit Alt = again. What a great product that was!

Chris
  • Administrators
  • 10727 posts
  • Last active:
  • Joined: 02 Mar 2004
Although it's designed to be self-explanatory, it should probably have documentation added for it someday.

In the meantime, the basic steps are to press the Record button, type your keystrokes and mouse clicks, then press the Stop button. You should then have a working script (or at least something you can copy and paste, or polish up into a working script).

Bruce
  • Members
  • 5 posts
  • Last active: Dec 22 2005 10:08 PM
  • Joined: 21 Dec 2005
I see. That's not as useful as the old DOS ProKey was. You could be in an application, Lotus perhaps or the mainframe, and have a series of keystrokes you needed to repeat involving using the arrows to move the cursor, and you could start recording, do the keystrokes, and end the macro. You'd always get the correct keystrokes because you actually did them in the application where you want to use them.

This seems like a neat product, but you almost have to take a class to learn how to use it, and it still doesn't seem to do what I really want.

Thanks for the info and help.

Chris
  • Administrators
  • 10727 posts
  • Last active:
  • Joined: 02 Mar 2004

You'd always get the correct keystrokes because you actually did them in the application where you want to use them.

That's true for AutoScriptWriter too. It's designed to record what you do and in which window you do it. It's designed to activate the target window as part of the macro, so that when you play it back, your keystrokes and mouse clicks get sent to the right window.

Bruce
  • Members
  • 5 posts
  • Last active: Dec 22 2005 10:08 PM
  • Joined: 21 Dec 2005
ok, I tried it. I opened excel, and clicked the cell I want. Then I started autoscript writer, and clicked the red record button. Then I clicked the excel spreadsheet again, because that's where I want to start executing the keystrokes that I'll be recording. I typed "this is a test" into the cell, then hit the down arrow. Then I clicked "stop" for autoscriptwriter. I still don't see how to assign it to a key. It asked me about saving it, I don't really care about saving it, I just want to create a keyboard macro on the fly. Also, it has all kinds of junk in the file, stuff like "winwait, if winnoactice,, yada yada yada. With ProKey, all you did was hit the programed key, and all the recorded keystrokes were sent to the keyboard buffer.

Is there an easier way?

Laughing Man
  • Members
  • 84 posts
  • Last active: Oct 25 2007 04:43 AM
  • Joined: 28 Apr 2005
Try copying and pasting what you need into a .ahk file.
"I thought what I'd do was I'd pretend I was one of those deaf-mutes" ~ Laughing Man - GITS:SAC

fjord
  • Members
  • 1 posts
  • Last active: Dec 22 2005 05:22 PM
  • Joined: 22 Dec 2005
As another first time user, I have to agree with Bruce. It sure would be nice if AutoScriptWriter would assist with the subsequent step(s) of assigning the recorded keystokes to a specific shortcut key (for example prompting to press the desired key combination), saving the ahk file (or appending to another script), and executing the ahk file.

Maybe this could be done with a new "Assign Key" button. ;-)

ps. What does the "Record & Shrink" button do?

Bruce
  • Members
  • 5 posts
  • Last active: Dec 22 2005 10:08 PM
  • Joined: 21 Dec 2005
I'm not giving up on this product yet! I have an idea.

What I LOVED about ProKey back in the good old DOS days was if you had to repeat a set of key strokes 3 times, it would be easier to make a macro. It was SO QUICK, so simple! I'd know I was going to do the same set of keystrokes several times. I'd hit Alt = (i think it was alt =), then the key I wanted to program, perhaps Alt Z, then I'd enter my key strokes. When I hit the Alt = and the Alt Z, the application I'd be in would not receive those key strokes. After that, the application would receive the key storkes. When I was done, I'd hit Alt = again, and the key would be programed. If I hit Alt Z, the key strokes I had recorded would be sent to the keyboard buffer, just as if I had typed them all again. Now, I could save the key definition in a file if I wanted to, but when I used ProKey it was mostly to do on-the-fly macros like I just described.

What I was wondering... Could one write an AHK script that would program the Alt = key to do what I just described? Even if it didn't give you the option to pick what key gets programed, to be able to on-the-fly record keystrokes that will need to be repeated would be quite helpful!
If it would be easier, the Alt = key could start the recording, and a different key could end it.

I can think of so many uses for what in effect would be a windows version of ProKey.

How about it AHK gurus?

hamoid
  • Members
  • 19 posts
  • Last active: Nov 06 2006 10:45 AM
  • Joined: 17 Mar 2005
Too bad you didn't get a reply in half year...

I'm in the same situation you are. I used a programming language called Amiga E, and it had the same option. And it would save you so much time!

It's like you described: You hit a key to tell the macro recorder to listen, then you press some keys like Ctrl+X, Down, Down, Ctrl+V, Up, Delete. Then another key to tell the recorder you are done.

It's not practical to create an AHK file, assign a key and all that if you are just going to use this macro 30 times in your life.

I've been using AHK for a year or two now and I'm quite sure it can be done. I will have a quick look...

BoBo
  • Guests
  • Last active:
  • Joined: --
AutoScriptWriters Controls:
Button1 (starts recording)
Button 2-5 (floating button, stops recording)
Edit2 (edit field which conatins the recorded text/code/movements)

So start AutoScriptWriter hidden via an AHK Hotkey
Trigger its start/stop button via Control...
Get its recorded output via ControlGetTex
Close AutoScriptWriter using a Hotkey
Create a script by keeping the output using FileAppend

@ Geeks
nobody able to add some command line params to AU3 ASW ???

hamoid
  • Members
  • 19 posts
  • Last active: Nov 06 2006 10:45 AM
  • Joined: 17 Mar 2005
Thanks, I found something interesting at:

http://www.donationc... ... tml#DoOver

The problem is that it's very slow because it waits for selecting the original window. Since I don't need window / mouse recording, I deleted half of the code and works perfectly for me.

If someone wants a copy please ask. I don't want to upload it to my site because I didn't ask the author yet.

I'm working on a huge XML file and it helps very much. For example, in my text editor, I add some markers in the middle of the code, and then do a macro that searches for those markers, cuts blocks of text, searches for different markers, pastes in the new position. It saves me a lot of time =)

BoBo
  • Guests
  • Last active:
  • Joined: --
#SingleInstance, Force

SetTitleMatchMode, 2



ASWPath = C:\AutoHotkey\AutoScriptWriter\AutoScriptWriter.exe



!x::

	Run, %ASWPath%,, Min ; or fully hidden

	WinWaitActive, AutoScriptWriter II

	; ControlClick, Button8, AutoScriptWriter II ; window text button

	ControlClick, Button1, AutoScriptWriter II ; record button

Return



!y::

	BlockInput, On

	Control, Show,, Edit2, AutoScriptWriter II  ; activate edit field

	ControlGetText, RecordedCode, Edit2, AutoScriptWriter II ; get the code

	BlockInput, Off

	MsgBox % RecordedCode ; for testing

	FileAppend, %RecordedCode%, %A_Now%.ahk ; create file

	WinClose, AutoScriptWriter II ; well ...

Return
Feel free to tweak it to death :wink:

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004

It's not practical to create an AHK file, assign a key and all that if you are just going to use this macro 30 times in your life.

:shock: The amount of time that can/will be saved is worth it and more IMO... 30 times :shock: . I'll spend an hour on something that will save me a few hours and only use it once... :lol: