[Kc] Excel
Garrett Goebel
ggoebel at goebel.ws
Sun Sep 3 16:49:45 PDT 2006
Try a google search on: perl "win32::ole" excel
Whatever you can do in VBA you should be able to do in perl using
Win32::OLE.
The difficulty is in navigating the OLE object hierarchy. For which
you'll need to consult microsoft's excel documentation.
I don't know how a checkbox is represented internally. Is it an
ActiveX control or a NumberFormat property applied to a cell? I ran
across one reference to finding checkboxes in the Shapes collection.
If you can find example VBA code for what you want to do... you
should be able to convert it to Perl without too much difficulty.
cheers,
Garrett
On Sep 3, 2006, at 1:02 PM, djgoku wrote:
> On 9/2/06, Jay Hannah <jay at jays.net> wrote:
>>
>> Perhaps this is an opportunity for you to contribute a patch to
>> Spreadsheet::ParseExcel? I have several things across various CPAN
>> modules I've stumbled into that are in my to-do list to enhance. I'm
>> not very good at getting around to that list, but someday...
>
> I could for now add some VB to the master excel sheet (that is blank
> nothing is selected) that does something like this:
>
> Private Sub CheckBox1_Click()
> IF Worksheets("Sheet1").CheckBox1 = True Then
> Worksheets("Sheet1).Range("Z1") = 1
> ELSE
> Worksheets("Sheet1).Range("Z1") = 0
> ENDIF
> End Sub
>
> I was just thinking that in cell Y I could put the description of what
> the checkbox was refering to. Though I would have to change all the
> checkboxes in the sheet, which would take sometime, but then all I
> would need to do is parse just this rows true values. I know this
> isn't the ideal solution yet, but it would work, though if the master
> excel sheet ever changed I would have to change/add this stuff to it.
> _______________________________________________
> kc mailing list
> kc at pm.org
> http://mail.pm.org/mailman/listinfo/kc
>
More information about the kc
mailing list