Transfer Excel data into Isodraw
Hello,
I am required to make changes to a large number of CGM files. Below I will list whats need to be done and the areas I am stuck on. I am to do the following:
Tasks
-Remove unwanted elements
-Insert Text Input #1 at certain location (Data from Spreadsheet)
-Insert Text Input #2 + Input #3 at certain location (Input #2 from spreadsheet and is CGM filename - Input #3 is Data is from spreadsheet)
Current Progress
The removal of unwanted elements I have just completed using the following (Unfortunately the elements to be removed are on the same layer as the wanted elements so i cannot simply delete a layer - hence the long workaround) :
Macro CustomSelection
SELECT RECTANGLE 0 0 650 8.2 with_partial add direct
SELECT RECTANGLE 0 0 7.6 600 with_partial add direct
SELECT RECTANGLE 837.2 0 843 600 with_partial add direct
SELECT RECTANGLE 0 591.7 842.6 600 with_partial add direct
SELECT RECTANGLE 632.6 0 842.6 83.2 with_partial add direct
DELETE SELECTION
End Macro
The next step is to add in 2 text elements which will contain Input #1 and Input #2+#3 (I am confident I can add empty text elements myself).
The Difficult Bit:
Prior to this (or after depending which you recommend happens first) I need to retrieve data from an excel speardsheet. The name of the CGM file is also in a cell on a row within the Excel sheet - we can use this as an identifier to ensure the correct information is transfered to the correct CGM, this filename is also Input #2.
I have no idea if/how Isodraw can read a excel document. I know Perl can and I know Isodraw can execute Perl commands. Below is the research I have found so far:
Running a Perl Script Within Isodraw
http://structuredauthoring.org/arbrtext-isodraw/running-a-perl-script-in-arbortext-isodraw/
Accessing Excel Document via Perl
I am no programmer by any means, I am new to macros and I doing what I can where I can but I feel obtaining the cell data from a spreadsheet is beyond my current ability. If anyonce can assist at any step along the way, it would be greatly appreciated! I believe many individuals would benefit from this knowledge too, now and in the future as this is pretty powerful stuff!
Thanks again.
Alan

