Hi Joe,

If I understood your question correctly, there are two commands that could be 
useful for you:
   getInfo("window.title")
returns the name of the active window
  getInfo("window.type")
tells you if the active window is an image, a table or else
And you can get a list of all non-image windows with the command 
  getList("window.titles")

I hope it helps.

Giovanni

-----Original Message-----
From: Joe Vandergracht <[email protected]> 
Sent: Thursday, 15 February 2024 00:31
To: [email protected]
Subject: selecting and renaming text windows in a macro

I am trying to record a macro where I

1. perform a simple action on an existing text window (in my current case I 
delete the first 10 rows) 2. save the text file to my hard drive 3. import that 
saved text file as a text image 

I can record the above macro but it is specific to the name of the text window. 
 In my case the first line in the macro is:

Table.deleteRows(0, 19, "c13_r7_E110_PE50_uni_lin2_auto_20X_Height.csv");

So if I open some other text file, the macro does not apply

How can I tell the macro to select the text window that is "active" in some 
sense.  I know how to select image windows, but not how to select a text 
window.  

On a related note, it would be good to be able to rename a text window.  This 
is different from renaming an image window and I don;t know how to do so.

thanks

Joe vanderGracht

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html

Reply via email to