MacroExpress and Libraries – Part 2

Continuation of an earlier post: http://www.meyerwebsite.com/macroexpress-and-libraries/.

In addition to the “simple” commands like text expansion and automating simple commands, Macro Express can also be used to perform very complicated tasks across different platforms and sources. Rather than outlining all possible options – a task I’m not qualified to do! – I’ll focus on a basic workflow that I use frequently. I think of it as “working through a list.” This is a way to automate some of the most repetitive tasks for managing bibliographic records.

Background

This process works best when you have two things:

  1. A clearly defined list of records that need to be changed/updated/moved/deleted.
  2. A clearly defined process to perform.

By “clearly defined” I mean defined with mathematical precision; Macro Express takes things very literally and you have to be precise. It’s also helpful to imagine all possible cases to anticipate problems along the way. Let’s look at each step in turn.

A Clearly Defined List

To start, you will need a clearly defined list. Thing like system supplied ID number for bib records, MFHDs, items, or patrons are ideal; ISBNs, ISSN, and exact name might seem good enough but they usually cause problems.

I generate almost all of these lists through the reporting side of Voyager and have started always including the system supplied ID numbers. Depending on the nature of your query, you may need to de-duplicate this list.

A Clearly Defined Process

I’ll share my general approach and then some tips and tricks. My process is usually to set my mouse aside and try accomplish what I need to do using only keyboard shortcuts. MacroExpress can control the mouse…but this always seemed very problematic; keyboard shortcuts are the way to go. Start the process with the ID number of a record to change on your clipboard. As you go, write down you commands on a pad of paper in sequential order. This will take some time.

A Recipe

Text File Begin Process: "filename.txt"
Activate Window: "Name of ILS system"
Wait For Window: "Name of ILS system"

This set of commands starts reading a text file (one that contains all of the system ID numbers) and activates the window you want to use.

Next, bring up your search window and search by that system number. Do this by using the “Text Type” command in MacroExpress and following your paper notes. You may have to incorporate some “Delays” to give your machine time to keep up. This should bring up the record you want to look at.

Do something! Ideally, you’ll write more MacroExpress code to automate the process totally.

However, a very simple option and one that is useful in complicated situations is to simply add the following command.

Wait for Key Press: <something weird>

Replace <something weird> with a key that you are unlikely to use in that process. Now you have a macro that brings up a record and waits… waits until you make and save a change, waits until you inspect it, just waits. You can set a time-out requirement if that is helpful.

Lastly, write some text type functions that will close and save the record you are working on. I also like to use the following command to keep a record of my work

Variable Modify String: Append %T1% to Text File

This copies the system ID number from the original text file and appends it to a new text file that will list all the records changed in the process.

 

Macro Express and Libraries

I’m a big fan of library automation technologies and I thought I would write up a short piece on one of my favorite tools – Macro Express – to share with the library world.

What is Macro Express

Macro Express describes itself as:

the premier Windows macro utility. With Macro Express, you can record, edit and play back mouse and keyboard macros. Its powerful tools and robust features will make you more productive.

Although it’s not glamorous, I think this description is pretty accurate. Macro Express works across the Windows OS to automate tedious tasks. My general outlooks is this: if it’s easy to do once but really hard to do 300 times, you should try creating a Macro to automate this work.

Setting up Macro Express

  1. Download from http://www.macros.com/. They provide a 30 day trial and the license fees are quite cheap. Totally recommend purchasing this for your library.
  2. It comes pre-loaded with a few macros but you’ll certainly want to create your own. One important distinction, a “macro” is stored in a “macro file.” So if you are creating a new macro, select “New Macro” and not “New Macro File.”
    macrosnip1
  3. Macro Express should then prompt you “Choose Default Activation.” Macros can be triggered in a number of different ways. The ones I use most often are:
    1. HotKey – This creates a “normal” action that mimics other keyboard shortcuts. Just like CTRL C and CTRL V trigger certain actions, you can program keyboard combinations to execute certain commands.
    2. ShortKey – This activation method uses a special identifier and allows you to execute a macro using a “short key.” I believe the system default is ##. For example, when I type “##ip” Macroexpress replaces that text with the EZ Proxy URL prefix. It’s awesome.
    3. No Activation – this is pretty obvious; this means that macros can only be run from the MacroExpress editor
  4. After selecting an activation option (I will survey all three approaches) click on “Scripting Editor” and you are ready to create a new macro!

Basic Macros

Let’s make a macro that adds your signature to things that we can activate with a ShortKey.

  1. Create a new macro.
  2. Set default activation as a shortkey. I’ll use my initials “ajm” as my shortkey.
  3. Click on scripting editor. This should bring you to the following screen:
    macrosnip2
  4.  This is the “Scripting Editor” window. All of the available commands are on the left side (under “Commands”) and the actual macro you are writing is on the right/main side of the screen (under “Macro Script”)
  5. To get started, you’ll need to add a command. Either find a command by expanding the categories or by searching for a command (bottom left corner). We are looking for the “text type” command which is under “Text.”
  6. Double click the command to add it to the macro or click the small arrows to add it to the macro.
  7. You will get a box that allows you to enter keystrokes. Type out your signature (or copy/paste it in the box.
  8. Click okay and look over your macro.
  9. To give your macro a name (which I recommend!) click on the properties tab from the top band and add a nickname. Then click “Save” in the upper left corner.
  10. Congratulations! You just created a new macro!

I’ll try and write other posts that detail the other activation methods and how they might be useful in a library context. More later!