Hmmmm. Not an Perl OLE expert, but, it seems GetPrecursorInfoFromScanNum returns a Variant array of C structs, not an variant array of integers according to the manual. Every example in the manual is C/C++, zero VB. Is your
"Output:
$VAR1 = [
'414.005279541016',
'1.83302424514875e-307',
'3.50253979763967e-310',
'1.36817960845299e-312',
'2.68156223007842e+154',
even valid compared to Thermo's official viewer for the file?
I think you need to try to get perl OLE to return an array of string, the strings will be binary garbage but should be 8+8+4+4 bytes long, then do an "unpack('FFll',$arr[
$i]);" on it to decode the C struct. Try looking for Visual Basic code for your control and see how its done there.
typedef struct tagMS_PrecursorInfo {
double dMonoIsoMZ;
double dIsolationMZ;
long nChargeState;
long nScanNumber;
} MS_PrecursorInfo;
I pulled that from the IDL inside your control. Its described the same way in manual page for GetPrecursorInfoFromScanNum. Can you point me to a sample raw file for this control?
Edit, try changing "my $arr = Variant( VT_VARIANT | VT_BYREF);" to
" my $arr = Variant( VT_ARRAY | VT_BYREF);"