AW: Windows Tasks
Hi all, please help my: I have in perl 5.6.1 635 stored hash with like this use MLDBM qw(DB_File); tie (my %ZeitDB, 'MLDBM', PC\\Share\\ZeitDB); If I open the hash in my new perl 5.8.6 811 with the same I have: MLDBM error: Second level tie failed, at ... Have somebody a solution ? P.S. delete the file (with lost all data) is not the solution (but work fine). Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
MLDBM error
sorry for wrong subject Hi all, please help my: I have in perl 5.6.1 635 stored hash with like this use MLDBM qw(DB_File); tie (my %ZeitDB, 'MLDBM', PC\\Share\\ZeitDB); If I open the hash in my new perl 5.8.6 811 with the same I have: MLDBM error: Second level tie failed, at ... Have somebody a solution ? P.S. delete the file (with lost all data) is not the solution (but work fine). Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
MLDBM error
I have create/stored the file with DB_File 1.73 and with DB_File 1.810 or 1.809 or 1.806 I can not open ! -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von [EMAIL PROTECTED] Gesendet: Donnerstag, 14. April 2005 09:58 An: Perl-Win32-Users@listserv.ActiveState.com Betreff: MLDBM error sorry for wrong subject Hi all, please help my: I have in perl 5.6.1 635 stored hash with like this use MLDBM qw(DB_File); tie (my %ZeitDB, 'MLDBM', PC\\Share\\ZeitDB); If I open the hash in my new perl 5.8.6 811 with the same I have: MLDBM error: Second level tie failed, at ... Have somebody a solution ? P.S. delete the file (with lost all data) is not the solution (but work fine). Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
what's wrong in Win32-OLE, DBD-ADO, Dynaloader or ............. i n my script
Hi all, if I write: -- Begin snip $|++;use strict;use warnings; #use DBD::ADO; #*1) use DBI; our ($dbh,$sth); my $DB=dbi:ADO:driver=Microsoft Access Driver (*.mdb);DBQ=Konverter.mdb;DRIVERID=25;DEFAULTDIR=M:\\TestLib\\Konverter_NE U\\;; $dbh=Connect($DB.'{AutoCommit=0}')or die; $sth=Prepare (INSERT INTO [TAB] VALUES (?,?),$DB); # *2) sub Connect { my $dbh = DBI-connect_cached(($_[0]=~/dbi:/i)?$_[0]:dbi:ODBC:$_[0]) or die Error connecting dbi:ODBC:$_[0].$DBI::errstr.\n;return $dbh } sub Prepare {my $sth=Connect($_[1])-prepare($_[0]) or die $DBI::errstr.\n;return $sth} END{print 1\n; $main::sth-finish; # *2) print 2\n;$main::dbh-disconnect;print 3\n} -- End snip I have this: --Begin STDOUT -- 1 2 Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154. Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154. 3 Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154 during global destruction. Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154 during global destruction. --End STDOUT -- if I uncomment 'use DBD::ADO' (*1) ) I have: --Begin STDOUT -- 1 2 3 Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154 during global destruction. Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154 during global destruction. --End STDOUT -- if I comment lines*2)(no prepare) and uncomment line *1) I have correct run --Begin STDOUT -- 1 2 3 --End STDOUT -- if I comment lines*2)(no prepare) and comment line *1) I have --Begin STDOUT -- 1 2 Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154. Win32::OLE(0.1702): GetOleObject() Not a Win32::OLE object at C:/Perl/site/lib/Win32/OLE/Lite.pm line 154. 3 --End STDOUT -- what's wrong ? ? ? I need the access AND the prepare AND the clear up in END-Block I need not the warnings/errors from Win32::OLE what's the difference I load 'DBD::ADO' in my script or DBI load 'DBD::ADO' ? ? I have: Perl v5.8.6 Binary build 811 DBI 1.46 Win32::OLE 0.1702 DBD::ADO 2.94 w2k SP4 Bests regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] www.adac.de www.adac.de ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
cdo Object or String
Hi all, I found in http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cdo/html/_o lemsg_fields_property_infostore_object_.asp : --- snip - CDO 1.2.1 Fields Property (InfoStore Object) The Fields property returns a single Field object or a Fields collection object. Read-only. Syntax objInfoStore.Fields objInfoStore.Fields(index) objInfoStore.Fields(proptag) objInfoStore.Fields(name) --- end snip - and --- snip - If your application is running as a Microsoft Windows NT® service, you cannot access the Microsoft Exchange Public Folders through the normal hierarchy because of a notification conflict. You must use the InfoStores Fields property to obtain the Microsoft Exchange property PR_IPM_PUBLIC_FOLDERS_ENTRYID, property tag H66310102. This represents the top-level public folder and allows you to access all other public folders through its Folders property. Example This code fragment accesses the root of the Public Folders subtree of a message store: Dim objSess As Session ' assume logged on to valid session Dim objInfoStore As InfoStore ' assume opened and valid Dim strPFRootID As String ' binary entry ID returned as hex string Dim objPFRoot As Folder ' root folder of Public Folders tagPFRootID = H66310102 ' PR_IPM_PUBLIC_FOLDERS_ENTRYID strPFRootID = objInfoStore.Fields(tagPFRootID) ' entry ID ??? MsgBox Public Folders root folder ID = strPFRootID Set objPFRoot = objSession.GetFolder(strPFRootID) --- end snip - if I write: --- snip - $cdo=Win32::OLE-new(MAPI.Session); $cdo-logon(); foreach (in $cdo-{Infostores}){ if (my $RootID=$_-Fields(1714487554)){# 1714487554 = H66310102 --- end snip - $RootID is object and not string This object is a field-object from infostore and has not an identifier for a folder (I need for $folder=$cdo-GetFolder($RootID);) !! Is that my error ? or is 2 errors in the µsoft's web-page (1. String is not object; 2. Fields-object not contains folder-ID) ? Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
AW: Probably need help with a hash to do this
-Ursprüngliche Nachricht- Von: steve silvers [mailto:[EMAIL PROTECTED] Gesendet: Mittwoch, 10. November 2004 17:02 An: [EMAIL PROTECTED] Betreff: Probably need help with a hash to do this I have no idea how to do this. I have tens of thousands of lines in a text file that houses numbers for internal purposes. There are usually 20 on a line, with a range of (01 - 80). Example: my @data = ( '08|10|13|16|19|22|28|32|33|37|41|46|47|50|51|52|53|55|71|76', '06|11|16|19|20|29|31|35|39|44|50|57|58|59|60|62|71|72|76|77', '03|05|06|08|09|10|11|16|17|28|31|41|42|43|45|46|56|61|69|79', '05|07|12|13|15|16|17|19|21|25|41|45|47|48|53|58|63|69|76|79', '01|02|04|07|08|12|17|19|25|27|29|34|38|44|47|60|62|64|73|75', '01|04|06|07|08|09|11|13|14|19|25|26|37|39|41|60|61|62|63|80', '04|07|09|17|19|27|28|29|39|41|46|51|52|54|57|58|60|68|74|80' ); foreach (@data) { split(/|/,$_) - foreach (@data) {map{$a{$_}++}split(/\|/,$_)} print $_ is $a{$_} times found \n for sort keys %a -- # Here is where I need to run I think a hash to tell me the two, three, four, five, numbers that appear on each line out of the above 7 lines. As an example; say I only have two lines in my text file. 01|02|03|04|05 01|03|05|33|36 The output needs to say that the above found 01,03,05 in the two sets of numbers. Does this make sense? I'm sure this is pretty easy for someone who know hashes real good. } Any help greatly appreciated Steve ___ 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
AW: Formatting seconds help
for $seconds(3598 .. 3661) { $_=gmtime $seconds;/(\d\d):(\d\d):(\d\d)/; 0+$1 printf %d hour ,$1; 0+$2 printf %d minutes,$2; 0+$3 (($1 || $2) print ( and ),printf %d seconds,$3);print \n } give me: -- Perl -- 59 minutes and 58 seconds 59 minutes and 59 seconds 1 hour 1 hour and 1 seconds 1 hour and 2 seconds 1 hour and 3 seconds 1 hour and 4 seconds 1 hour and 5 seconds 1 hour and 6 seconds 1 hour and 7 seconds 1 hour and 8 seconds 1 hour and 9 seconds 1 hour and 10 seconds 1 hour and 11 seconds 1 hour and 12 seconds 1 hour and 13 seconds 1 hour and 14 seconds 1 hour and 15 seconds 1 hour and 16 seconds 1 hour and 17 seconds 1 hour and 18 seconds 1 hour and 19 seconds 1 hour and 20 seconds 1 hour and 21 seconds 1 hour and 22 seconds 1 hour and 23 seconds 1 hour and 24 seconds 1 hour and 25 seconds 1 hour and 26 seconds 1 hour and 27 seconds 1 hour and 28 seconds 1 hour and 29 seconds 1 hour and 30 seconds 1 hour and 31 seconds 1 hour and 32 seconds 1 hour and 33 seconds 1 hour and 34 seconds 1 hour and 35 seconds 1 hour and 36 seconds 1 hour and 37 seconds 1 hour and 38 seconds 1 hour and 39 seconds 1 hour and 40 seconds 1 hour and 41 seconds 1 hour and 42 seconds 1 hour and 43 seconds 1 hour and 44 seconds 1 hour and 45 seconds 1 hour and 46 seconds 1 hour and 47 seconds 1 hour and 48 seconds 1 hour and 49 seconds 1 hour and 50 seconds 1 hour and 51 seconds 1 hour and 52 seconds 1 hour and 53 seconds 1 hour and 54 seconds 1 hour and 55 seconds 1 hour and 56 seconds 1 hour and 57 seconds 1 hour and 58 seconds 1 hour and 59 seconds 1 hour 1 minutes 1 hour 1 minutes and 1 seconds Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Gesendet: Dienstag, 2. November 2004 19:02 An: [EMAIL PROTECTED] Betreff: Formatting seconds help Does anyone have a simple routine or a way that I can format my seconds. Say I have: $seconds = '3600'; I want the output to say 1 hour $seconds = '5567'; I want the output to say 1 hour 54 minutes and 64 seconds Something like that that will break down the amount of days, hours, minutes, and seconds. Thank you Allan ___ 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
Excel table can not delete
Hi all, this: -- use DBI; my $dbh=DBI-connect( DBI:ADO:driver=Microsoft Excel Driver(*.xls);READONLY=FALSE;. CREATE_DB=$Ziel;DBQ=$Ziel;,{RaiseError=1}); $dbh-do(DROP TABLE TAB\$); $dbh-disconnect(); -- makes the table TAB empty ! However, I want to delete the table! (I have more than one table) What is wrong ? This box had no excel installation ! (OLE can not do) Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] www.adac.de www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Linger time of socket in Win32::Internet ?
Hello all, its possible to set the linger time (in SO_LINGER) of a socket if I have the objects from Win32::Internet ? use Win32::Internet; $INET=new Win32::Internet(); $res=$INET-FTP($FTP,);# Wat is in $res ? $FTP-QueryOption('67'); # Error 12018 The supplied handle is the wrong type for the requested operation # '67' is for INTERNET_DIAGNOSTIC_SOCKET_INFO and give a structure with Socket descriptor inside (I hope) $INET-QueryOption('67'); # Error 12018 The supplied handle is the wrong type for the requested operation # '67' is for INTERNET_DIAGNOSTIC_SOCKET_INFO and give a structure with Socket descriptor inside (I hope) $FTP-Close(); # the socket must also close after the linger time - If I kill the script --- all opened sockets must close -- I hope this is possible over DataReciveTimeout, DataSendTimeout, ControlReceiveTimeout, ControlSendTimeout and Linger time Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Control IBM Personal Communications
Hi all, how can I Control IBM Personal Communications with perl ? Objects: 'PCOMM.autECLSession.1' 'PCOMM.autECLOIA.1'? 'PCOMM.autECLPS.1' ? I would be happy if anybody have a example script ! thanks Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Can I unzip with perl a WinZip does had a password ?
Hi all, Can I extract with perl a WinZip-file which is protected with a password ? I looked in 'Archive::Zip' and can find no password-parameter. Best regards/Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] www.adac.de www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Logon by cdo
Hi all, if I run this: -- - use Win32::OLE; use Win32::OLE::Const; Win32::OLE- Initialize(Win32::OLE::COINIT_OLEINITIALIZE); $cdo = Win32::OLE- new(MAPI.Session); $cdo- Logon(,,0,1,0,0,'Server'.\n.'Mailbox') ; -- -- by a computer where the user of Mailbox is not logon, I have a message-box Enter Password with ask me for User Name, Domain Name and Password. How can I make this informations in the script ? ? Mit freundlichen Grüssen | best regards Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] www.adac.de www.adac.de ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
AW: What is wrong with this?
chomp missing Mit freundlichen Grüssen Joachim Görner Informationsverarbeitung Systemtechnik Basisdienste (ISB) ADAC e.V., Am Westpark 8, 81373 München Tel.: (089) 76 76 27 83 Fax: (089) 76 76 28 82 mailto:[EMAIL PROTECTED] www.adac.de -Ursprüngliche Nachricht- Von: steve silvers [mailto:[EMAIL PROTECTED] Gesendet: Dienstag, 12. August 2003 15:53 An: [EMAIL PROTECTED] Betreff: What is wrong with this? I don't understand why the output of the below snippet kind of blows up.. --TEXT FILE test.txt-- 03|04|09|14|15|18|24|27 09|23|24|26|27|28|33|35 10|11|13|15|17|18|19|22 07|08|13|17|22|23|24|25 03|06|07|08|11|12|16|17 02|05|06|09|12|18|19|22 --SCRIPT #!Perl -w use strict; use vars qw(%counts $numbers @numbers); open(FILE,test.txt) || die Can't open file $^E; while(FILE) { chomp;# --- --- push(@numbers, split(/\|/,$_)); } close(FILE); # - # Get Count.. $counts{$_}++ foreach @numbers; foreach (sort { $counts{$b} = $counts{$a} } keys %counts) { print qq( $_ - $counts{$_} \n); } -- RESULTS -- 18 - 3 24 - 3 09 - 3 07 - 2 23 - 2 15 - 2 08 - 2 17 - 2 19 - 2 03 - 2 11 - 2 12 - 2 13 - 2 06 - 2 22 - 2 22 - 1 25 - 1 17 - 1 35 - 1 27 - 1 02 - 1 05 - 1 16 - 1 33 - 1 04 - 1 26 - 1 10 - 1 14 - 1 27 - 1 28 - 1 Why do the last numbers as it seems is blowing out and not keep a nice form like the rest of the results? It seems likes it's just the last numbers? 22 - 1 25 - 1 17 - 1 35 - 1 27 - 1 Any suggestions Steve _ MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*. http://join.msn.com/?page=features/virus ___ 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