Login  Register

Re: I can't run a macro

Posted by Robert Baer on Oct 08, 2009; 3:18pm
URL: http://imagej.273.s1.nabble.com/I-can-t-run-a-macro-tp3690875p3690877.html

It is difficult to know exactly what your macro is designed to do from the
information you provide.  If we suppose you want to do a series of
instructions on the currently selected image, one strategy is to start
recording your macro sequence with an Image | Rename command and then rename
the image something like TestImage.  This will produce a macro line like:
rename("TestImage");

This will rename any selected image to a common name before preforming the
macro sequence and assures any macro commands doing a named reference will
"know" what your image window is called.  A more sophisticated approach is
to assign the current image name to a variable, but this will take learning
a little bit about programming.  If you need a more specific answer, you
need to provide us with your macro code.

Rob

----- Original Message -----
From: "Virginia Borroni" <[hidden email]>
To: <[hidden email]>
Sent: Thursday, October 08, 2009 8:33 AM
Subject: I can't run a macro


> Hi,
> When I run a macro, it only works with the images I used to create it.
> When I try to run the macro in another images (with different names)  it
> doesn't run and a legend appear telling me that the image is not  open.
> How can I edit the macro in the way it can run with any image? I  don't
> know anything about programing!!!
> Thanks a lot!!!
> Virginia
>
>
>
>
> Dra. Maria Virginia Borroni
> INIBIBB
> C La Carrindanga Km 7 CC857. B8000FWB.
> Bahia Blanca. Buenos Aires. Argentina.
> Tel.#: 54-291-4861201. interno 127
> Fax#: 54-291-4861200
> [hidden email]
>
>
> ----------------------------------------------------------------
> This message was sent using IMP, the Internet Messaging Program.
>