Win32 show nothing
this program show me nothings :( use Win32::GUI; $main = Win32::GUI::Window-new( -name = 'Main', -width = 100, -height = 100, ); $main-AddLabel(-text = Hello, world, -name = 'label'); $main-Show(); Win32::GUI::Dialog(); sub Main_Terminate { -1; } whats wrong? i have been installed win32::GUI win32::API win32::OLE Perl v5.6.1 built for MSWin32-x86-multi-thread -- S pozdravem, (Aben) [EMAIL PROTECTED] ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Win32 show nothing
Don't you need to put in a 'Main loop() or 'run main' command at the end to start the event loop? -Original Message- From: (Aben) Roman Fordinál [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 3:02 PM To: [EMAIL PROTECTED] Subject: Win32 show nothing this program show me nothings :( use Win32::GUI; $main = Win32::GUI::Window-new( -name = 'Main', -width = 100, -height = 100, ); $main-AddLabel(-text = Hello, world, -name = 'label'); $main-Show(); Win32::GUI::Dialog(); sub Main_Terminate { -1; } whats wrong? i have been installed win32::GUI win32::API win32::OLE Perl v5.6.1 built for MSWin32-x86-multi-thread -- S pozdravem, (Aben) [EMAIL PROTECTED] ___ 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
Determining if a Windows Server?
I need to be able to determine whether or not the computer that a script is running on is a Windows NT or 2000 server or if it is not. Does anyone know how to do this? I tried looking at Win32::GetOSVersion() but this won't work. I have tried searching on CPAN but haven't found anything. Thanks * Eric Hawley, Network Services Intern * Office of Information Technology * Ohio Department of Natural Resources * Phone: (614) 265-1028 * Mailto:[EMAIL PROTECTED] ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Re: Win32 show nothing
At 09:02 2002-10-10 +0200, Aben wrote: whats wrong? Note sure, but try to specify -top and -left coordinates as well. /J -- --- -- -- -- -- - - - Johan LindströmSourcerer @ Boss Casinos [EMAIL PROTECTED] Latest bookmark: Laziness - brian_d_foy's Journal http://use.perl.org/~brian_d_foy/journal/8285 dmoz (1 of 4): /Computers/Programming/Languages/Perl/ 25 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Re: Determining if a Windows Server?
Hawley, Eric wrote: I need to be able to determine whether or not the computer that a script is running on is a Windows NT or 2000 server or if it is not. Does anyone know how to do this? I tried looking at Win32::GetOSVersion() but this won't work. I have tried searching on CPAN but haven't found anything. how about $^O (see perldoc perlfunc) -- Alan F. Dickey - Interaction and Realization http://www.intac.com/~afdickey mailto:[EMAIL PROTECTED] VOX: 908-273-3232 Cell: 908-334-0932 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Win32::AdminMisc problems
Hi Guys, I get the following error when I execute my perl script from the browser. But when I execute the program by double clicking, it works fine. Any guesses?? I see the result in the test.txt file Password is correct Heres' the code #! D:\Perl\bin\Perl.exe use strict; use Win32::AdminMisc; open(OUT_EXT,test.txt); $domain = abcdefg; $user = confidential; $password = confidential; if( Win32::AdminMisc::UserCheckPassword($domain, $user, $password)) { print OUT_EXT Password is correct.\n; } else { print OUT_EXT Password is not correct.\n; } Here's the error --- CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: Can't locate Win32/AdminMisc.pm in @INC (@INC contains: D:/Perl/lib D:/Perl/site/lib .) at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. BEGIN failed--compilation aborted at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. - Tom Wyant --- Many thanks for your help. Thanks and Regards, Hari CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Unicode
Good Day All I am trying to access a Com DLL using Perl. The DLL was written in Visual Basic and return a "ByRef szData as String" Variable. When I pass Data to it, it receives the data and works. The problem is when retrieving data back from this DLL. The Visual Basic String is equal to BSTR under Visual C. I need to return Data back from the DLL. If anybody know how to solve this I would appreciate it use strict; use Win32::OLE; use Text::ParseWords; Win32::OLE-Initialize ( Win32::OLE::COINIT_OLEINITIALIZE ); my $ReaderList; my @Readers; my $Reader; my $Data; my $ucData; my $card; my $Error; my $count; my $iRet = -1; my $iLen; my $pReader = \$Reader; my $pData = \$ucData; my $pError = \$Error; my $filename; $card = Win32::OLE-new ( MSCard.SomeCard ) or die Oops!!\n; $ReaderList = $card-GetCardReaderList( $pError ); @Readers = quotewords(',', 0, $ReaderList); foreach $Reader( @Readers ) { $iRet = $card-ConnectToCard ( 0, $pReader, $pError ); if ( $iRet == 0 ) { last; } } if ( $iRet == 0 ) { $filename = /SerialNo; $iLen = $card-GetFileLen($filename, $pError); print File Length: $iLen\n; if ( $iLen 0 ) { print Error $Error\n; } $iRet = $card-GetSerialNo( $pData, $pError); } print Card: $card\n; print ReaderList: $ReaderList\n; print Reader: $Reader\n; print Error: $Error\n; printf iRet: %d\n, $iRet; print Data: $Data\n; Ronald Mundell EMAIL: [EMAIL PROTECTED] 105 West Street Ground Floor B-Block Room: BG3 Phone: 881-3751(Office) 083 411 1107(Mobile)
RE: Determining if a Windows Server?
Whew! I thought this was an easy one, but I just spent nearly an hour finding out *any* way to find this out. And here it is: Look at the contents of the following registry value: HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions/ProductTy pe It will have one of 3 values: WinNT -- Workstation (or Professional for Win2K) ServerNT-- Server LanmanNT-- Advanced Server (but I found this on an NT PDC, too) -Original Message- From: Alan Dickey [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 7:50 AM Cc: '[EMAIL PROTECTED]' Subject: Re: Determining if a Windows Server? Hawley, Eric wrote: I need to be able to determine whether or not the computer that a script is running on is a Windows NT or 2000 server or if it is not. Does anyone know how to do this? I tried looking at Win32::GetOSVersion() but this won't work. I have tried searching on CPAN but haven't found anything. how about $^O (see perldoc perlfunc) -- Alan F. Dickey - Interaction and Realization http://www.intac.com/~afdickey mailto:[EMAIL PROTECTED] VOX: 908-273-3232 Cell: 908-334-0932 ___ 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: Determining if a Windows Server?
Tony White wrote: Whew! I thought this was an easy one, but I just spent nearly an hour finding out *any* way to find this out. And here it is: Look at the contents of the following registry value: HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions/ProductTy pe It will have one of 3 values: WinNT -- Workstation (or Professional for Win2K) ServerNT-- Server LanmanNT-- Advanced Server (but I found this on an NT PDC, too) Thanks, Tony! As a summary for those interested, I put together this little script: -- use Win32; # compare various OS info: print \$^O = '$^O'\n; my @osinfo = Win32::GetOSVersion(); print Win32::GetOSVersion() = '@osinfo'\n; @osinfo = Win32::GetOSName(); print Win32::GetOSName() = '@osinfo'\n; use Win32::TieRegistry; my $producttype = $Registry-{'HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\ProductOptionsProduct Type'}; print HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions\\ProductType = '$producttype'\n; -- on my machine (W2K Professional SP3) this produces: $^O = 'MSWin32' Win32::GetOSVersion() = 'Service Pack 3 5 0 2195 2' Win32::GetOSName() = 'Win2000 Service Pack 3' HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions\ProductType = 'WinNT' Cheers. -- Alan F. Dickey - Interaction and Realization http://www.intac.com/~afdickey mailto:[EMAIL PROTECTED] VOX: 908-273-3232 Cell: 908-334-0932 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: How can I figure out whether it is binary file or ASCII file under one directory?
Can you be any more specific than various binary files? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 12:54 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: How can I figure out whether it is binary file or ASCII file under one directory? Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ 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: Perl and Strange File Names
I can't test it on W2K but readdir worked on XP with ActiverPerl build 633. It's not pure Perl but you can try ... @files=`dir /b/a`; -Original Message- From: Carlo7 [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 02, 2002 11:04 AM To: [EMAIL PROTECTED] Subject: Perl and Strange File Names Importance: Low Hello I Need to print file listings on win32 (w2000). When I glob or readdir i miss files with strange names like !=MyDir=! .message ..cvs etc. Is there a way I can get at these weird file names? Perl doesn't seem to want to list them ... TIA Karl ___ 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: How can I figure out whether it is binary file or ASCII file under one directory?
Like .bin, .exe files, The format of the file is binary instead of ASCII. Thanks Lixin -Original Message- From: Stovall, Adrian M. [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 2:06 PM To: [EMAIL PROTECTED] Subject: RE: How can I figure out whether it is binary file or ASCII file under one directory? Can you be any more specific than various binary files? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 12:54 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: How can I figure out whether it is binary file or ASCII file under one directory? Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ 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 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: How can I figure out whether it is binary file or ASCII file under one directory?
Given a filename, use the -B or -T operators. See perldoc ferlfunc HTH Stacy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 1:34 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: How can I figure out whether it is binary file or ASCII file under one directory? Like .bin, .exe files, The format of the file is binary instead of ASCII. Thanks Lixin -Original Message- From: Stovall, Adrian M. [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 2:06 PM To: [EMAIL PROTECTED] Subject: RE: How can I figure out whether it is binary file or ASCII file under one directory? Can you be any more specific than various binary files? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 12:54 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: How can I figure out whether it is binary file or ASCII file under one directory? Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ 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 ___ 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
How can I figure out whether it is binary file or ASCII file under one directory?
Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: How can I figure out whether it is binary file or ASCII file under one directory?
Why not use the -B operator to test the file for binary contents? if( -B $file) { # file is binary } else { # file is not binary } Carter. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 10:54 AM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: How can I figure out whether it is binary file or ASCII file under one directory? Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ 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
[PMX:#] RE: How can I figure out whether it is binary file or ASCII file unde r one directory?
Title: RE: How can I figure out whether it is binary file or ASCII file unde r one directory? Try reading the first 128 bytes of the file, and scanning for any characters 32 (except maybe x1B,x0c,x0a,x0d) ESC,TOF,CR,LF or 127. However, this might be a problem with some extended ASCII characters. George -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 1:54 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: How can I figure out whether it is binary file or ASCII file unde r one directory? Dear all, A question, How can I figure out whether it is binary file or ASCII file under one directory using perl? Does perl have a function for that? I have a project to pick up various binary files from some directories. Thanks in advance! Have a nice day! Lixin ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Win32::Process and Sockets
I am trying to write a server for a Windows machine that is always listening on a particular port. When the Server accepts a connection it should create a new process and transfer the socket. The parent process should go back to listening. I do this in the following way: Server: while (1) { while(my $connection = $listen_socket-accept) { SpawnConnection($connection); $connection-close; } } sub SpawnConnection { my $socket = shift; Win32::Process::Create($ProcessObj, c:\\perl\\bin\\perl.exe, perl dbserverchild.pl $socket, 0, NORMAL_PRIORITY_CLASS, .); } In dbserverchild.pl, I get the socket by doing: my $socket = shift(@ARGV); This does not work. My question is, how do I pass a socket from one process to another? I have tried implementing my server using fork, but fork seems to behave unreliably (doesn't always create a child process). Any help would really really be appreciated. Thanks! Neel __ Do you Yahoo!? Faith Hill - Exclusive Performances, Videos More http://faith.yahoo.com ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Re: Win32::AdminMisc problems
Hari - You've got me. It seems to me if Win32::AdminMisc is installed on your server _and_ your browser has access to it, this shouldn't happen. But I've seen it come by on the mailing list. You might want to root around in the archives and see what comes up. Tom Krishna, Hari [EMAIL PROTECTED]@listserv.ActiveState.com on 10/10/2002 10:15:16 AM Sent by:[EMAIL PROTECTED] To:[EMAIL PROTECTED] cc: Subject:Win32::AdminMisc problems Hi Guys, I get the following error when I execute my perl script from the browser. But when I execute the program by double clicking, it works fine. Any guesses?? I see the result in the test.txt file Password is correct Heres' the code #! D:\Perl\bin\Perl.exe use strict; use Win32::AdminMisc; open(OUT_EXT,test.txt); $domain = abcdefg; $user = confidential; $password = confidential; if( Win32::AdminMisc::UserCheckPassword($domain, $user, $password)) { print OUT_EXT Password is correct.\n; } else { print OUT_EXT Password is not correct.\n; } Here's the error --- CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: Can't locate Win32/AdminMisc.pm in @INC (@INC contains: D:/Perl/lib D:/Perl/site/lib .) at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. BEGIN failed--compilation aborted at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. - Tom Wyant --- Many thanks for your help. Thanks and Regards, Hari CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs This communication is for use by the intended recipient and contains information that may be privileged, confidential or copyrighted under applicable law. If you are not the intended recipient, you are hereby formally notified that any use, copying or distribution of this e-mail, in whole or in part, is strictly prohibited. Please notify the sender by return e-mail and delete this e-mail from your system. Unless explicitly and conspicuously designated as E-Contract Intended, this e-mail does not constitute a contract offer, a contract amendment, or an acceptance of a contract offer. This e-mail does not constitute a consent to the use of sender's contact information for direct marketing purposes or for transfers of data to third parties. Francais Deutsch Italiano Espanol Portuges Japanese Chinese Korean http://www.DuPont.com/corp/email_disclaimer.html ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Win32::AdminMisc problems
Tom - I didnot understand root around in the archieves? Did you wanted me to search thru the archieves on the cpan and roth sites?? Its soo frustrating..I am too close to the solution and yet very far. -Original Message- From: Thomas R Wyant_III [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 03:28 PM To: [EMAIL PROTECTED] Subject: Re: Win32::AdminMisc problems Hari - You've got me. It seems to me if Win32::AdminMisc is installed on your server _and_ your browser has access to it, this shouldn't happen. But I've seen it come by on the mailing list. You might want to root around in the archives and see what comes up. Tom Krishna, Hari [EMAIL PROTECTED]@listserv.ActiveState.com on 10/10/2002 10:15:16 AM Sent by:[EMAIL PROTECTED] To:[EMAIL PROTECTED] cc: Subject:Win32::AdminMisc problems Hi Guys, I get the following error when I execute my perl script from the browser. But when I execute the program by double clicking, it works fine. Any guesses?? I see the result in the test.txt file Password is correct Heres' the code #! D:\Perl\bin\Perl.exe use strict; use Win32::AdminMisc; open(OUT_EXT,test.txt); $domain = abcdefg; $user = confidential; $password = confidential; if( Win32::AdminMisc::UserCheckPassword($domain, $user, $password)) { print OUT_EXT Password is correct.\n; } else { print OUT_EXT Password is not correct.\n; } Here's the error --- CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: Can't locate Win32/AdminMisc.pm in @INC (@INC contains: D:/Perl/lib D:/Perl/site/lib .) at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. BEGIN failed--compilation aborted at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. - Tom Wyant --- Many thanks for your help. Thanks and Regards, Hari CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs This communication is for use by the intended recipient and contains information that may be privileged, confidential or copyrighted under applicable law. If you are not the intended recipient, you are hereby formally notified that any use, copying or distribution of this e-mail, in whole or in part, is strictly prohibited. Please notify the sender by return e-mail and delete this e-mail from your system. Unless explicitly and conspicuously designated as E-Contract Intended, this e-mail does not constitute a contract offer, a contract amendment, or an acceptance of a contract offer. This e-mail does not constitute a consent to the use of sender's contact information for direct marketing purposes or for transfers of data to third parties. Francais Deutsch Italiano Espanol Portuges Japanese Chinese Korean http://www.DuPont.com/corp/email_disclaimer.html ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Win32::AdminMisc problems
I'd check permissions on the directory. Likely you're not running the program as the same id interactively and through the webserver. Use www.sysinternals.com filemon to monitor inetsrv.exe to see if you're getting permission denied. -Original Message- From: Krishna, Hari [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 4:11 PM To: 'Thomas R Wyant_III'; [EMAIL PROTECTED] Subject: RE: Win32::AdminMisc problems Tom - I didnot understand root around in the archieves? Did you wanted me to search thru the archieves on the cpan and roth sites?? Its soo frustrating..I am too close to the solution and yet very far. -Original Message- From: Thomas R Wyant_III [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 03:28 PM To: [EMAIL PROTECTED] Subject: Re: Win32::AdminMisc problems Hari - You've got me. It seems to me if Win32::AdminMisc is installed on your server _and_ your browser has access to it, this shouldn't happen. But I've seen it come by on the mailing list. You might want to root around in the archives and see what comes up. Tom Krishna, Hari [EMAIL PROTECTED]@listserv.ActiveState.com on 10/10/2002 10:15:16 AM Sent by:[EMAIL PROTECTED] To:[EMAIL PROTECTED] cc: Subject:Win32::AdminMisc problems Hi Guys, I get the following error when I execute my perl script from the browser. But when I execute the program by double clicking, it works fine. Any guesses?? I see the result in the test.txt file Password is correct Heres' the code #! D:\Perl\bin\Perl.exe use strict; use Win32::AdminMisc; open(OUT_EXT,test.txt); $domain = abcdefg; $user = confidential; $password = confidential; if( Win32::AdminMisc::UserCheckPassword($domain, $user, $password)) { print OUT_EXT Password is correct.\n; } else { print OUT_EXT Password is not correct.\n; } Here's the error --- CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: Can't locate Win32/AdminMisc.pm in @INC (@INC contains: D:/Perl/lib D:/Perl/site/lib .) at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. BEGIN failed--compilation aborted at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. - Tom Wyant --- Many thanks for your help. Thanks and Regards, Hari CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs This communication is for use by the intended recipient and contains information that may be privileged, confidential or copyrighted under applicable law. If you are not the intended recipient, you are hereby formally notified that any use, copying or distribution of this e-mail, in whole or in part, is strictly prohibited. Please notify the sender by return e-mail and delete this e-mail from your system. Unless explicitly and conspicuously designated as E-Contract Intended, this e-mail does not constitute a contract offer, a contract amendment, or an acceptance of a contract offer. This e-mail does not constitute a consent to the use of sender's contact information for direct marketing purposes or for transfers of data to third parties. Francais Deutsch Italiano Espanol Portuges Japanese Chinese Korean http://www.DuPont.com/corp/email_disclaimer.html ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Re: Determining if a Windows Server?
Alan Dickey wrote: Tony White wrote: Whew! I thought this was an easy one, but I just spent nearly an hour finding out *any* way to find this out. And here it is: Look at the contents of the following registry value: HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions/ProductTy pe It will have one of 3 values: WinNT -- Workstation (or Professional for Win2K) ServerNT-- Server LanmanNT-- Advanced Server (but I found this on an NT PDC, too) Thanks, Tony! As a summary for those interested, I put together this little script: -- use Win32; # compare various OS info: print \$^O = '$^O'\n; my @osinfo = Win32::GetOSVersion(); print Win32::GetOSVersion() = '@osinfo'\n; @osinfo = Win32::GetOSName(); print Win32::GetOSName() = '@osinfo'\n; use Win32::TieRegistry; my $producttype = $Registry-{'HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\ProductOptionsProduct Type'}; print HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions\\ProductType = '$producttype'\n; -- on my machine (W2K Professional SP3) this produces: $^O = 'MSWin32' Win32::GetOSVersion() = 'Service Pack 3 5 0 2195 2' Win32::GetOSName() = 'Win2000 Service Pack 3' HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Control/ProductOptions\ProductType = 'WinNT' That doesn't exist on my 98 box. Try this one (works on 98SE) and see if it works there: use strict; use Win32::TieRegistry (Delimiter = '/'); my $reg = $Registry-{'LMachine/Software/Microsoft/Windows/CurrentVersion/'} or die Can't find the Windows CurrentVersion key: $^E; my $ProductName = $reg-{ProductName}; my $ProductType = $reg-{ProductType}; my $Version = $reg-{Version}; my $SubVersionNumber = $reg-{SubVersionNumber}; my $VersionNumber = $reg-{VersionNumber}; print ProductName='$ProductName'\n; print ProductType='$ProductType'\n; print Version='$Version'\n; print SubVersionNumber='$SubVersionNumber'\n; print VersionNumber='$VersionNumber'\n; __END__ Also what do get get for this PSIX version: use strict; use POSIX qw(uname); my @a = uname (); my @tags = qw(OS-Name Hostname OS-Version OS-Release Machine-Type); foreach (my $ii = 0; $ii @a; $ii++) { print $tags[$ii]: $a[$ii]\n; } __END__ -- ,-/- __ _ _ $Bill Luebkert ICQ=162126130 (_/ / )// // DBE Collectibles Mailto:[EMAIL PROTECTED] / ) /-- o // // http://dbecoll.tripod.com/ (Free site for Perl) -/-' /___/__/_/_ Castle of Medieval Myth Magic http://www.todbe.com/ ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
RE: Win32::AdminMisc problems
There are no permission problems on the directory. I have lots of other mail programs that are written in PERL and are executed via browser. They execute just fine. Also, I just tried what Ryan wanted me do. #! D:\Perl\bin\Perl.exe print Content-type: text/html \n\n; And it return a blank page.. Thanks, Hari. -Original Message- From: Gould, Kevin [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 04:26 PM To: Krishna, Hari; Thomas R Wyant_III; [EMAIL PROTECTED] Subject: RE: Win32::AdminMisc problems I'd check permissions on the directory. Likely you're not running the program as the same id interactively and through the webserver. Use www.sysinternals.com filemon to monitor inetsrv.exe to see if you're getting permission denied. -Original Message- From: Krishna, Hari [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 4:11 PM To: 'Thomas R Wyant_III'; [EMAIL PROTECTED] Subject: RE: Win32::AdminMisc problems Tom - I didnot understand root around in the archieves? Did you wanted me to search thru the archieves on the cpan and roth sites?? Its soo frustrating..I am too close to the solution and yet very far. -Original Message- From: Thomas R Wyant_III [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 10, 2002 03:28 PM To: [EMAIL PROTECTED] Subject: Re: Win32::AdminMisc problems Hari - You've got me. It seems to me if Win32::AdminMisc is installed on your server _and_ your browser has access to it, this shouldn't happen. But I've seen it come by on the mailing list. You might want to root around in the archives and see what comes up. Tom Krishna, Hari [EMAIL PROTECTED]@listserv.ActiveState.com on 10/10/2002 10:15:16 AM Sent by:[EMAIL PROTECTED] To:[EMAIL PROTECTED] cc: Subject:Win32::AdminMisc problems Hi Guys, I get the following error when I execute my perl script from the browser. But when I execute the program by double clicking, it works fine. Any guesses?? I see the result in the test.txt file Password is correct Heres' the code #! D:\Perl\bin\Perl.exe use strict; use Win32::AdminMisc; open(OUT_EXT,test.txt); $domain = abcdefg; $user = confidential; $password = confidential; if( Win32::AdminMisc::UserCheckPassword($domain, $user, $password)) { print OUT_EXT Password is correct.\n; } else { print OUT_EXT Password is not correct.\n; } Here's the error --- CGI Error The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are: Can't locate Win32/AdminMisc.pm in @INC (@INC contains: D:/Perl/lib D:/Perl/site/lib .) at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. BEGIN failed--compilation aborted at D:\inetpub\wwwroot\Intranet\cgi-bin\xyz.pl line 2. - Tom Wyant --- Many thanks for your help. Thanks and Regards, Hari CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. You may NOT use, disclose, copy or disseminate this information. If you are not the intended recipient, please contact the sender by reply e-mail immediately. Please destroy all copies of the original message and all attachments. Your cooperation is greatly appreciated. Columbus Regional Hospital 2400 East 17th Street Columbus, Indiana 47201 ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs This communication is for use by the intended recipient and contains information that may be privileged, confidential or copyrighted under applicable law. If you are not the intended recipient, you are hereby formally notified that any use, copying or distribution of this e-mail, in whole or in part, is strictly prohibited. Please notify the sender by return e-mail and delete this e-mail from your system. Unless explicitly and conspicuously designated as E-Contract Intended, this e-mail does not constitute a contract offer, a contract amendment, or an acceptance of a contract offer. This e-mail does not constitute a consent to the use of sender's contact information for direct marketing purposes or for transfers of data to third parties. Francais Deutsch Italiano Espanol Portuges Japanese Chinese Korean http://www.DuPont.com/corp/email_disclaimer.html ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs CONFIDENTIALITY NOTICE: This e-mail message, including all attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged
Browse local LAN
Hi list, what module should I use to browse file shares on our home LAN? I tried simply 'opendir(DIR,\\server\share)', also with escaped \'s, but it wouldnt do the trick. Searching for 'net'-modules yields 1000 answers, I will be greatfull for any pointers! Regards, Torbjørn Lindahl ___ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs