subesc has asked for the wisdom of the Perl Monks concerning the following question:

I am nearly finished with my script that reads a series of Excel Files and outputs certain data into a text file.

I have no problem reading specific cells using the Spreadsheet::ParseExcel module, but now I am required to read a text box object and I am not sure how to go about this.

Is another module required to accomplish this or can I manage using ParseExcel? I know the name of the text box in every file, but I need to be informed of how to reference it through Perl.

Thanks for any assistance.

Replies are listed 'Best First'.
Re: Reading Excel Files
by marto (Cardinal) on Jul 13, 2006 at 18:13 UTC
    Hi subesc,

    As has been suggested I think the only way you can get this data is via Win32::OLE. There are some useful links in Re: Excel VB Controls which I posted in response to a similar question which should help to simplify this task for you.

    Hope this helps.

    Martin
Re: Reading Excel Files
by Ieronim (Friar) on Jul 13, 2006 at 18:10 UTC
    I think it can be done with the OLE module, but it's qouite complicated task requiring good knowledge of Visual Basic for Excel :(

    Maybe it's simpler to write a VB macro which will write the data from the text box to a specified cell, and then access this data using Spreadsheet::ParseExcel?

Re: Reading Excel Files
by shonorio (Hermit) on Jul 13, 2006 at 22:23 UTC
    I'm not clear about what you want. Your text box show up as a like pop up ? Maybe you can use Win32::GuiTest to select this text box and get it's value.

    Solli Moreira Honorio
    Sao Paulo - Brazil