Win32::API -where wrong in code

2001-10-23 Thread Abhra Debroy
Hi I am trying to retrieve the label displayed of menu item in windows explorer. For that I used win32 Api function GetMenuString( int GetMenuString(HMENU, hMenu, WORD wIDItem, LPSTR lpString, int nMaxCount, WORD wFlag)). But it is not giving right result. I also used GetMenuItemCount. It is gi

Win32 ::API and WIn32::Setupsup -- Window Handle and Menu handle

2001-10-23 Thread Abhra Debroy
Hi I am finding out handle to a window and menu of that window. In below mentioned script I am finding window with title "PCE - [api-getmenu]" and printing its handle and handle to it's menu. My problem is every time I open the window and run the program,it gives different handle to both window

Re: System calls through a CGI script

2001-10-23 Thread Brett W. McCoy
On Wed, 24 Oct 2001, Daniel Falkenberg wrote: > I am working on a CGI script that needs to execute this command from a > sub within the script... > > system("/usr/sbin/adduser test"); > > I can issue this from a single non-CGI script and it works fine. I have > also double checked the permission

System calls through a CGI script

2001-10-23 Thread Daniel Falkenberg
Hi all, I am working on a CGI script that needs to execute this command from a sub within the script... system("/usr/sbin/adduser test"); I can issue this from a single non-CGI script and it works fine. I have also double checked the permission on the file but it still won't execute this syste

Re: Concatination

2001-10-23 Thread Michael Fowler
On Tue, Oct 23, 2001 at 03:34:26PM -0500, SAWMaster wrote: > $cookie = $addtocart_co->cookie(-name=>'incart', -value=>$pid . ":" . > $pidsincart, -expires=>'+1h'); print > $cookie, $pid, and $pidsincart are all predefined with values. > Use of uninitialized value in concatenation (.) or string a

Re: exit 0 or exit 1

2001-10-23 Thread Joe Echavarria
Those it also apply to shell scripts ? --- Jeff 'japhy' Pinyan <[EMAIL PROTECTED]> wrote: > On Oct 23, Joe Echavarria said: > > > What is the diference when you write a subroutine > >and you type > > Well, exit() doesn't return from a subroutine -- it > stops the program. So > long as you k

Re: exit 0 or exit 1

2001-10-23 Thread Jeff 'japhy' Pinyan
On Oct 23, Joe Echavarria said: > What is the diference when you write a subroutine >and you type Well, exit() doesn't return from a subroutine -- it stops the program. So long as you know that... The exit() function returns the status of your program upon ending -- a successful program exit

exit 0 or exit 1

2001-10-23 Thread Joe Echavarria
Hi there, What is the diference when you write a subroutine and you type exit 1; or exit 0; Thanks, Joe Echavarria __ Do You Yahoo!? Make a great connection at Yahoo! Personals. http://personals.yahoo.com -- To unsubscribe, e-

Re: either or

2001-10-23 Thread Christopher Solomon
On Wed, 24 Oct 2001, birgit kellner wrote: > I'm sure this has been covered billion times: > Until recently, I assumed that the binary operator "||" functions as > either-or. Now I read that it evaluates the left side and, if it evaluates > true, doesn't care about the right. So if I want to te

Re: either or

2001-10-23 Thread Jeff 'japhy' Pinyan
On Oct 24, birgit kellner said: >My understanding is that either-or (i.e. excluxive or) on strings would >best be done with "xor". Is that correct? Yes, use 'xor'. There is no ^^ (like there is && and ||). -- Jeff "japhy" Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/ RPI Ac

either or

2001-10-23 Thread birgit kellner
I'm sure this has been covered billion times: Until recently, I assumed that the binary operator "||" functions as either-or. Now I read that it evaluates the left side and, if it evaluates true, doesn't care about the right. So if I want to test whether either $one or $two exists, || would be

RE: Net::Ping

2001-10-23 Thread Peter Scott
At 07:13 AM 10/23/01 -0400, Gary L. Armstrong wrote: >I had similar results as Daniel before I read the docs, but from his code he >is using ICMP so I didn't think he was having the same problem. Dang, I didn't read properly, sorry. The old reflex kicked off automatically. In that case, I'd nee

Re: Maintaining Order of Keys in a Hash

2001-10-23 Thread Peter Scott
At 05:48 AM 10/23/01 -0400, Rex Arul wrote: >Peter: > >I am not sure how I can differ or accept your statement, which is sort of >appealing to me. Let me run this by you. On querying a database, I am >getting a recordset of this form: > >2001-10-01 01:00:00 Amy 1020normal 55

Re: beginners Digest 23 Oct 2001 16:44:18 -0000 Issue 435

2001-10-23 Thread zentara
> From: Mandar Tambe <[EMAIL PROTECTED]> > Can anybody gives me information about How to handle events in Perl? > Like performing any action on clicking the button by mouse or Invoking menu > item. > Is there any Perl module available for handle these types of events. Look at the Perl/Tk module a

RE: Responding to child process request for input

2001-10-23 Thread Bob Showalter
> -Original Message- > From: Ted Markowitz [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, October 23, 2001 4:41 PM > To: [EMAIL PROTECTED] > Subject: Responding to child process request for input > > > Oh great IPC gurus, > > I'm trying to run another program from my script that takes a n

Responding to child process request for input

2001-10-23 Thread Ted Markowitz
Oh great IPC gurus, I'm trying to run another program from my script that takes a number of command-line args. Normally, the child program will execute successfully---using readpipe or a variation on open to execute it---when given the proper arg list and it sets a return code which I can examine

Concatination

2001-10-23 Thread SAWMaster
Hello group. I am getting an error in my apache logs that is not clear to me what exactly is wrong. I get the same error in different scripts, and completely different lines, so I'll just post one and hopefully once I know how to fix this one, I can fix the rest. Line 27: $cookie = $addtocar

RE: Combine passwd files

2001-10-23 Thread is09
Here's one for you. I am hoping someone can criticize this or suggest some better way of writing parts of this code. Regards I.S #!/usr/bin/perl -w use strict; my $pass1 = "./passwd"; my $pass2 = "./passwd.old"; open PASS1 , "< $pass1" or die "Error opening $pass1: $!\n";; open PASS2 , "< $

Re: How to Invoke application for further action on it.

2001-10-23 Thread Michael Fowler
On Mon, Oct 22, 2001 at 12:33:37PM +0530, Abhra Debroy wrote: > My problem is code after "system('C:/from21/AbhraDownload/pce.exe'); " does > not get executed unless PCE(Application) is closed. It even do not print > 'After Invoking application'; > > How I can Overcome the situation. Use fork a

Re: Checking logs in NT

2001-10-23 Thread RaFaL Pocztarski
"Najamuddin, Junaid" wrote: > 1. How to go thru a log.txt file to check for an error string thru perl script Show me how does the typical error message look like and I'll show you how to find such messages using Perl. If you just want to see lines which contain "error" string anywhere, use from

Re: Recursive includes

2001-10-23 Thread RaFaL Pocztarski
Joyce Harris wrote: > What does this mean and how do I fix it? I have compare the page to other .shtml >pages and the coding does not seem to be any different. Any help at all would be >appreciated. You probably want the server to include one file in another, and vice versa. Instead of includi

RE: Re: Excel

2001-10-23 Thread is09
I am actually looking for a row count in the while spreadsheet nt just a range. La cuisson du pot au feu <[EMAIL PROTECTED]> wrote: >Le Mardi 23 Octobre 2001 16:24, F.H a écrit : >You need to use >Range["B9"]->CurrentRegion->Rows->Count; >Range["B9"]->CurrentRegion->Column->Count; > > >hi, Alon

Recursive includes

2001-10-23 Thread Joyce Harris
Let me preface this by saying that while this may not be the appropriate mailing list, this seems to be one of the most responsive lists so I'm hoping that someone will be able to help me. I have an .shtml page that routinely returns the following error in the apache logs: [Tue Oct 23 12:26:0

Checking logs in NT

2001-10-23 Thread Najamuddin, Junaid
Hi,folks thanks in advance Can anyone help me out on two things I am using perl in win NT environment 1. How to go thru a log.txt file to check for an error string thru perl script 2. How to check and start NT services thru perl script Your help is highly appreciated thanks junaid -

Re:How to assign an array variable to an Entry Box

2001-10-23 Thread Jorge Goncalvez
Hi, I have this: $_varRef=@_; $frm->Entry(-relief => "sunken", -textvariable => \$_varRef, -width => $_Globals{LABEL_LENGTH}, #-anchor => "w", -bg => "white") ->pack(-anchor => "w");

Excel

2001-10-23 Thread F.H
Hi All, Anyone knows how to get a row/column count instead of specifying them as in foreach my $row (2..130) foreach my $column (2..130) Thanks I.S use strict; use Win32::OLE qw(in with); use Win32::OLE::Const 'Microsoft Excel'; $Win32::OLE::Warn = 3;# die on er

Re: better solutions for NetFtpServer1.0.7

2001-10-23 Thread RaFaL Pocztarski
root wrote: > Thank Mr.Poczterski and Mr.Holstein , Pocztarski > I have try to upgrade my old > perl version to 5.6.1. > The only problem is Syslog beacuse in the test steps I have > /lib/syslog.t failed test 5. > > The error is in the row 58: > > print defined(eval { openlog('perl','nd

Re: conversion of ascii -> "English Text" on solaris

2001-10-23 Thread Luke Bakken
Your version of perl must not support that discipline on the binmode function. I think you need perl 5.6.1 for this. Try the three-argument open() call : perldoc -f open Good luck!! Luke On Mon, 22 Oct 2001, dan.kelley wrote: > > no dice: i tried adding this immediately after the open: > >

Re: create hash and print all elements?

2001-10-23 Thread Etienne Marcotte
yep, sorry for reading the message too fast I saw after when reading the post with the my @color_array = ( ["sky", "blue"], ["grass", "green"], ["apple", "red"] ); that there was a key/value :-) RaFaL Pocztarski wrote:

Re: How to split it?

2001-10-23 Thread Etienne Marcotte
sprintf and printf are commands really useful IMO. http://www.perldoc.com/perl5.6.1/pod/func/sprintf.html it formats the output to the type you write beside the % sign. in ANSI C you can only use those (printf and scanf) to get input and output. lets say you want to put your times with 04 inste

RE: regexp question

2001-10-23 Thread Richard_Cox
On 23 October 2001 12:21 Jerry Preston [mailto:[EMAIL PROTECTED]] wrote: > I want to break down this name, pgrap.C4A2S1R.1.gif, into 4 parts. I > can do it with split: > > ( $a1,$a2,$a3,$a4 ) = split( /\./, $program ); > > How do I do it with s/\b(\.)\b(\.)\b(\.)\b(\.)/? >

Re: create hash and print all elements?

2001-10-23 Thread RaFaL Pocztarski
Etienne Marcotte wrote: > if you only want to print what's in your hash, you can do > > my %hash = qw(sky blue grass green apple red); > foreach (%hash){ print "$_ = $hash{$_}"; } Have you tried that code? It will print: grass = greengreen = apple = redred = sky = blueblue = %hash in a list

Re: Deleting an element from an array.

2001-10-23 Thread Etienne Marcotte
use strict; my @array=qw(a b c d e f g h); splice(@array,1,1); print "new list = @array"; will return: a c d e f g h In your mesasge you say "I know I want to remove the second value, $array[2]. How should I do this?.." but second value has [1] and not [2] :-) You can remove multiple elements

Re: Assistance with Array.

2001-10-23 Thread Etienne Marcotte
As the other replies said, they start with [0]. for you #1 question, you can define the number of elements explicitly by doing $#array = number. But I don't know if there is any maximum = use strict; my @array=(1,2,3,4,5,6,7); $#array=10; my $nb=@array; print "Number of elements in the ta

Re: Attention anyone.

2001-10-23 Thread Etienne Marcotte
require is just "pasting" the contents of the file in your script. to what i read it's better to use includes The experts will give you a more detailled answer:-) Etienne Brian wrote: > While reading, I think I figured this out, I just want to verify > with someone first. > > #!/usr/bin/perl

better solutions for NetFtpServer1.0.7

2001-10-23 Thread root
Hi all, Thank Mr.Poczterski and Mr.Holstein , I have try to upgrade my old perl version to 5.6.1. The only problem is Syslog beacuse in the test steps I have /lib/syslog.t failed test 5. The error is in the row 58: print defined(eval { openlog('perl','ndelay',local0')}) ? "ok 5\n" : "n

Mouse Event Handling with PERL...

2001-10-23 Thread Mandar Tambe
Hello all Can anybody gives me information about How to handle events in Perl? Like performing any action on clicking the button by mouse or Invoking menu item. Is there any Perl module available for handle these types of events. Please treat as a urgent. Thanks in advance Mandar Tambe

Re: Deleting an element from an array.

2001-10-23 Thread RaFaL Pocztarski
wh wrote: > This works but it can't be this easy, so tell this true beginner what's > wrong with it! I checked it with print "@array\n"; and got an error message > about an "uninitialized value in join or string" I don't know how to deal > with. > > @array = (1, 2, 3, 4, 5); > delete $array[2];

Re: regexp question

2001-10-23 Thread register
my $string = 'pgrap.C4A2S1R.1.gif'; my @s = ($string =~ /(?:\.)*(\w+)(?:\.)*/g); the arraytores the elements the //g makes it find more than one match ... post again if you need more explanation ... hth On Tue, Oct 23, 2001 at 06:20:31AM -0500, Jerry Preston shaped the electrons to read: > Hi,

Re: NetFtpServer prerequisites.

2001-10-23 Thread RaFaL Pocztarski
root wrote: > In the cpan site I don't find the module Sys::Syslog. That's strange, I got: 6 modules found in 6 distributions matching 'Sys::Syslog' http://search.cpan.org/search?mode=module&query=Sys::Syslog What version of perl do you have? Because Sys::Syslog has been in standard perl

Re: NetFtpServer prerequisites.

2001-10-23 Thread Andrea Holstein
Root wrote: > > Hi all, > > Now I would like to install the module Net-FtpServer1.0.7. > When I write "perl Malefile.PL", I see this message: > > Warnings: prerequisite Sys::Syslog 0 not found at (eval 1 ) line 220. > > In the cpan site I don't find the module Sys::Syslog. > > Where Can

regexp question

2001-10-23 Thread Jerry Preston
Hi, I want to break down this name, pgrap.C4A2S1R.1.gif, into 4 parts. I can do it with split: ( $a1,$a2,$a3,$a4 ) = split( /\./, $program ); How do I do it with s/\b(\.)\b(\.)\b(\.)\b(\.)/? Thanks, Jerry -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional c

Re: undef function

2001-10-23 Thread register
The first lien makes sure that subsequently $b will not be defined anymore. THis is necessary whenyou are somehow using the variable $b in subsequent lines but wanna make sure that there is no previous values to corrupt it. i have seen it used in a lopp where $b is a global variable for example a

RE: Net::Ping

2001-10-23 Thread Gary L. Armstrong
I had similar results as Daniel before I read the docs, but from his code he is using ICMP so I didn't think he was having the same problem. However, per the docs, you have to be root to use ICMP. Does this then mean that when run as "not-root" the ICMP parameter is ignored and defaults to TCP? T

Re:Write to a file

2001-10-23 Thread Jorge Goncalvez
Hi, How I can write to the beginning of a file this: option vendor-encapsulated-options "install:KLOR_1:%$_varRef:$_varRef:$_varRef"; that can be for exemple: option vendor-encapsulated-options "install:KLOR_1:%pre2.2:standard:E1302.fr"; In fact I wanted $_varRef to be an array which coul

Re: undef function

2001-10-23 Thread Martin
delete deletes a hash key and undef undefines a variable nafiseh saberi wrote: > > hi all... > I read about "undef" a lot > but.. > I dont understand the difference between "undef" and "delete".. ? > and why do we use undef... > thx > __ > Best regards ..

Re: Test

2001-10-23 Thread RaFaL Pocztarski
Eric Wang wrote: > Hi guys, I just configured pine to accept emails from [EMAIL PROTECTED] > to go into another folder. > > Please do not reply and disregard this email. Don't get me wrong, but why couldn't you just wait for any real message to test your config? - RaFaL Pocztarski, [EMAIL PROTE

How to use NSGMLS Parser

2001-10-23 Thread RAHUL SHARMA
Hi All, Can anyone tell me the way to use NSGMLS exe coz I'm in a bit tight schedule. I have a DTD file, SGML document and a entity file. Thanks, Rahul.

NetFtpServer prerequisites.

2001-10-23 Thread root
Hi all, Now I would like to install the module Net-FtpServer1.0.7. When I write "perl Malefile.PL", I see this message: Warnings: prerequisite Sys::Syslog 0 not found at (eval 1 ) line 220. In the cpan site I don't find the module Sys::Syslog. Where Can I find this module ? Thanking in

Re: undef function

2001-10-23 Thread nafiseh saberi
thx a lotand a lot... can you understand it.. undef $b; while $a=; #the name of handler's file chop; $b=$a; $b=~s/\s+//g; } thx again. __ Best regards . Nafiseh Saberi Iran .

Re: undef function

2001-10-23 Thread Rex Arul
$val=undef; #undef is more like a value here. undef ($objRS); #undef is more of a function here undef(%hash); #and here too -- Rex - Original Message - From: <[EMAIL PROTECTED]> To: "nafiseh saberi" <[EMAIL PROTECTED]> Cc: "perl" <[EMAIL PROT

Re: undef function

2001-10-23 Thread nafiseh saberi
thx a lot my problem is the meaning of this code... undef $b; while $a=; chop; $b=$a; $b=~s/\s+//g; } can u understand it... __ Best regards . Nafiseh Saberi Iran . notes

Re: undef function

2001-10-23 Thread register
undef is not really a function ... delete is ... undef is (although many might disagree with me) more like a value not unlike 1,2 or 'cowabunga' that just says there is no value (hope this makes sense) but when u set a hash to undef it effectively deletes the hash from existance ... (again i migh

Re: Maintaining Order of Keys in a Hash

2001-10-23 Thread Rex Arul
Peter: I am not sure how I can differ or accept your statement, which is sort of appealing to me. Let me run this by you. On querying a database, I am getting a recordset of this form: 2001-10-01 01:00:00 Amy 1020normal 555.234 2001-10-01 01:00:00JoeDoe1525

How weird is this...

2001-10-23 Thread Daniel Falkenberg
Hi all, ATM I am playing with cookies. I just came accross a really weird problem I am having... I would set the cookie in my browser and have in expire in 10 minutes. Then I logged out of my webpage and have the cookie deleted. This worked fine. I then logged back into my webpage and notice