Setting extended File Properties

2004-04-19 Thread Phillips Thomas E Contr AFMC/ITON

 Does anyone have any examples of or know how to change the extended
 properties of a file (Comment, Title, Subject, Keywords, etc.) from within
 Perl?
 
 Have been looking at Win32::OLE, but I have not been able to change these
 extended properties.
 
 Thank you,
 Tom
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


archive::zip problem

2004-04-19 Thread Michael Meltzer
I wrote a little perl script to zip some textfiles on a windows box, send the archive 
via NET::FTP to a unix
box and decrompress the archive there.
On windows (NT)  I can decrompress the archive with WinZip but on unix (SuSe 8.2 and 
Solaris 7)
when running unzip I get the following error message:

mich: unzip Container.zip
Archive:  Container.zip
  End-of-central-directory signature not found.  Either this file is not
  a zipfile, or it constitutes one disk of a multi-part archive.  In the
  latter case the central directory and zipfile comment will be found on
  the last disk(s) of this archive.
unzip:  cannot find zipfile directory in one of Container.zip or
Container.zip.zip, and cannot find Container.zip.ZIP, period.

the file command on Linux:
mich: file Container.zip
Container.zip: Zip archive data, at least v2.0 to extract


here are the relevant parts of my program:



use Archive::Zip qw( :ERROR_CODES :CONSTANTS );
my $zip = Archive::Zip-new();
.

foreach $box (@boxes) {
print $box\n;
   ...
$member = $zip-addFile( document.$box);
}

$status = $zip-writeToFileNamed( Container.zip );
werror(040 Error while trying to zip\n$!\n, 2) if $status != AZ_OK;

--

instead of addFile command in foreach loop I also tried

$zip-addTreeMatching( '.', 'dir/*', 'document\.' );

after foreach loop with the same effect.

I hope somone  can help me.

Thanks in advance

Michael





--
+-- Michael Meltzer -+-+
|   AED-SICAD Aktiengesellschaft |   EMail : [EMAIL PROTECTED]  |
|   Lilienthal-Str. 7|   Phone : +49-89-45026-108  |
|   85579 Neubiberg  |   Fax   : +49-89-45026-113  |
++-+
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Win32::OLE and events from multiple source interfaces

2004-04-19 Thread Rajkumar Malli
At 09:15 PM 3/31/2004, Jan Dubois wrote:
On Wed, 31 Mar 2004 19:43:48 -0800, Rajkumar Malli [EMAIL PROTECTED]
wrote:

I have a ATL COM server which supports two connection point
interfaces IAsiaCommonEvent and IAsiaTestEvent along which 
it can fire COM events . Now, I can get events from either of 
these  connection points, one at a time. Is it possible to get
events from both? The WithEvents call on one interface seems
to overwrite the WithEvents call on the other interface.

Yes, Win32::OLE only supports one connection point per object.

Cheers,
-Jan

Is this not a limitation? Are there plans to fix this?

Thanks
Raj 

___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


R: problem with Geo::Shapelib

2004-04-19 Thread TELARO BARTOLOMEO
Thanks Randy,
I'm using ActivePerl 5.8.3 build 809. 
The author's module (Ari Jolma) write me there is no intentionally OS
specific syntax in the module
but he had never installed Geo::Shapelib in a Windows machine.

best regards 
bart

Bartolomeo Telaro
Presidio Tecnico Aeroportuale
ARPA Lombardia

-Messaggio originale-
Da: Randy Kobes
A: TELARO BARTOLOMEO
Cc: '[EMAIL PROTECTED]'
Inviato: 16/04/04 17.13
Oggetto: Re: problem with Geo::Shapelib

On Fri, 16 Apr 2004, TELARO BARTOLOMEO wrote:

 Hy all  I'm new of the list.

 I'm trying to compile Geo::Shapelib module from CPAN, after same
littles
 changes to Makefile.PL I successfully compiled it with Visual C 6.0,
but the
 test.pl crashes and makes
 perl crash to.

 Here the error:
 Free to wrong pool 222770 not 80100 at
C:/Perl/site/lib/Geo/Shapelib.pm
 line 333

 At that line the lib call a c-function (_SHPCreateObject) in
shapelib.dll

 I found in the list's archive that this kind of problem is created by
bugs
 in Perl's multithread support.

 How could I bypass it?

 Thank you in advanced

 Bart

This is a generic type of error - are you using the latest
ActivePerl (based on perl-5.8.3)? This has improved
threading support. If that doesn't help, it might mean
something in the module itself needs fixing.

-- 
best regards,
randy
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


R: R: problem with Geo::Shapelib

2004-04-19 Thread TELARO BARTOLOMEO

 Thanks Randy,
 I'm using ActivePerl 5.8.3 build 809.
 The author's module (Ari Jolma) write me there is no intentionally OS
 specific syntax in the module
 but he had never installed Geo::Shapelib in a Windows machine.

What might be worth investigating is if the module builds
and tests OK on a Unix Perl built with multi-threading
support; it might be a general threading issue, not
necessarily Win32 specific.

-- 
best regards,
randy

Ciao Randy
I dont' know on a unix Perl, but now I have built my perl with the flags
USE_MULTI and USE_ITHREADS desabled and so the module builds and tests OK. 
But I'm very ignorant about multi-threading,  is it useful? 
Shall I have any problem using perl without multi-threading support?

Thanks a lot 

Bartolomeo Telaro
Presidio Tecnico Aeroportuale
ARPA Lombardia
___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Win32::Daemon::Simple vs. SVCANY.EXE

2004-04-19 Thread Peter Guzis
My $0.02 on SRVANY.EXE:

The problem with SRVANY.EXE is that it does not integrate into your program.  It 
merely acts as a service wrapper.  This means when you decide to stop the service, 
SRVANY has no hooks into your program to tell it when and where to stop.  The only 
possible way to stop your program is for SRVANY to forcefully terminate it.  This can 
potentially lead to data loss and execution stopping at places you didn't intend.

Peter Guzis
Web Administrator, Sr.
ENCAD, Inc.
- A Kodak Company
email: [EMAIL PROTECTED]
www.encad.com 

-Original Message-
From: Jim Lancaster [mailto:[EMAIL PROTECTED]
Sent: Sunday, April 18, 2004 8:06 AM
To: [EMAIL PROTECTED]
Subject: Win32::Daemon::Simple vs. SVCANY.EXE


I've written a script to read the Windows event logs and write the
results to a MySQL database.  I'm currently using Win32::Daemon::Simple
to run it as a service, polling the logs every 15 minutes.  However, I'm
wondering if this is the best method to use.  It would appear to be
simpler to put my polling code in a continuous loop with a sleep()
command at the end and install the compiled app as a service using
SVCANY.EXE from the Windows Resource Kit.  What are the relative
advantages/disadvantages of the two methods?

Also, I intend to develop similar scripts to poll other logs (syslog,
Apache) on Linux.  I think it would be easier to create (and maintain)
the scripts if the basic code was platform independent.  I've seen
mention of using Proc::Background.  How would this fit in with what I am
trying to do?

Thanks,

Jim

___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Telnet module

2004-04-19 Thread Andrew Timberlake-Newell
 Can someone send me an example of how to use the debugging tools
input_log , and or
 dump_log in the Telnet module.  I'm trying to get a telnet to work
and it appears 
 there is a character that I can't match.  Here is an example of one of
my telnets 
 that work: 

 my ($file, $tn); 
 use Net::Telnet; 
 $tn=new Net::Telnet (Timeout =10,Prompt='//'); 

Anywhere after you have the object in $tn:

  $tn-input_log('log.txt');



___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Telnet module

2004-04-19 Thread Bullock, Howard A.








This is what I used to debug a Cisco
Telnet script. 



$session = Net::Telnet::Cisco-new(

 Host
= $host,

 Errmode =
'return',

 Input_log = $RootPath .
logs\\. $host . _input.log,

 Output_log = $RootPath .
logs\\. $host . _output.log,

 Dump_log =
$RootPath . logs\\. $host . _dump.log,

 Timeout =
20);











From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED]
Sent: Friday, April 16, 2004 10:24
PM
To:
[EMAIL PROTECTED]
Subject: Telnet module






Can someone send me an example of how to use the
debugging tools input_log , and or dump_log in the Telnet module. I'm
trying to get a telnet to work and it appears there is a character that I can't
match. Here is an example of one of my telnets that work: 

my
($file, $tn); 
use
Net::Telnet; 
$tn=new
Net::Telnet (Timeout =10,Prompt='//'); 
$tn-open('xxxmgx1');

$tn-waitfor
('/Login: /'); 
$tn-print('x');

$tn-waitfor
('/password: /'); 
$tn-print('x');

$tn-waitfor
('/:/'); 
$tn-print();

$tn-waitfor
('//'); 
@channels=$tn-cmd('dspchans');

print
@channels; 
exit;


Where
can I add the input_log and or dump_log in the example above? 

Thanks
in advance 

Lloyd






___
Perl-Win32-Users mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs