setting variable in certain cases

2005-04-14 Thread Jan Eden
Hi, I have a switch statement containing 10 different cases. in 5 of the cases, I need to set a variable to a certain value. The ways I could think about are: - setting the variable within each case statement, e.g. case 'slurp' { $parameters{type} = 'gallery'; ... } - use a se

Re: setting variable in certain cases

2005-04-14 Thread Offer Kaye
On 4/14/05, Jan Eden wrote: > > In example 1, I have to set the variable explicitly 5 times, in example 2, I > have to manually > list all cases outside the switch statement, which bears the risk of > forgetting to modify the > line once I extend the switch statement. > > So is there a better

what are utf8 barewords.?

2005-04-14 Thread Rajarshi Das
Hi, Barewords acccording to perldata.pod are "words that donot have any other meaning in grammar". 1) So, does this mean that any word which is not reserved is a bareword ? 2) What exactly would be a utf8 bareword ? Is it any utf8 encoded character ? Any examples ? Would "\x69\x22" qualify as a u

Re: setting variable in certain cases

2005-04-14 Thread Jan Eden
Hi, Offer Kaye wrote on 14.04.2005: >On 4/14/05, Jan Eden wrote: >> >>In example 1, I have to set the variable explicitly 5 times, in >>example 2, I have to manually list all cases outside the switch >>statement, which bears the risk of forgetting to modify the line >>once I extend the switch sta

RE: 'format' puzzle

2005-04-14 Thread Moon, John
Subject: 'format' puzzle How can I create a perl 'format' string that begins with a comment (#)? Eg. format STDOUT_TOP = # Field1 Field2 @<< @||| @||| . If I try '\#' then I see the backslash. I just want the pound char. TIA, -Sam I'm not sure where you want the "#" ... but DEV,S

Perl and visual Basic

2005-04-14 Thread DiGregorio, Dave
Could anyone help me? I need to start a PERL script from within my visual basic program. I have tried the shell command without success. To further compound the problem I also want to provide command line parameters. Thanks for any and all assistance David R. DiGregorio Vocollect 70

RE: Perl and visual Basic

2005-04-14 Thread Bob Showalter
DiGregorio, Dave wrote: > Could anyone help me? I need to start a PERL script from within my > visual basic program. I have tried the shell command without > success. To further compound the problem I also want to provide > command line parameters. I don't know VB, but I'm assuming the shell c

bareword test on z/OS unix.

2005-04-14 Thread Rajarshi Das
Hi, I am running perl-5.8.6 on z/OS unix. I am trying to display the character 'tau'. This on linux (RH) shows as is, meaning I can actually include the character 'tau' as it displays, in a perl script. But, if I try copy pasting the same character on a z/OS shell, I dont see the character, inst

setting PERL5LIB path

2005-04-14 Thread Manish Sapariya
Hi List, I have default MIME module installed and I have installed the lated version in one of my own directory. Any my perl code needs the latest version which I have installed in local_perl_lib. How do I instruct perl interpreter to use the latest one in the $PERL5LIB and not the one in the defau

Re: what are utf8 barewords.?

2005-04-14 Thread Chris Devers
On Thu, 14 Apr 2005, Rajarshi Das wrote: > Barewords acccording to perldata.pod are "words that donot have any > other meaning in grammar". > > 1) So, does this mean that any word which is not reserved is a > bareword ? Off the top of my head, every "token" of text in Perl is either: * an ope

Re: Searching for embedded EOF in binary

2005-04-14 Thread Jay Savage
On 4/13/05, John W. Krahn <[EMAIL PROTECTED]> wrote: > Jay Savage wrote: [snip] > I haven't used DOS in a while so I may be a little fuzzy on some of the > details. > > Sector size is based on the media, be it hard disk, floppy disk or whatever, > and is not carved in stone although most hard disk

Re: CGI advice

2005-04-14 Thread Wiggins d'Anconia
Mike Lesser wrote: Hi all. Okay, here's the latest. I've been screwing around with my first CGIs - pretty cool, now I see the appeal. Anyway, I'm fairly comfortable using MySQL and generating XML output from it, and printing it to files and stdout. Now I'd like to create the usual web interface t

Active Directory and Perl advice

2005-04-14 Thread Tim Wolak
Hi all, I am being asked to create a perl script to migrate AD accounts from one machine to another and also migrate their files and directory structure. Is there any good web sites I can take a look for some example scripts or any good books? Thanks in advance. Tim -- To unsubscribe, e-mail:

Re: Active Directory and Perl advice

2005-04-14 Thread Offer Kaye
On 4/14/05, Tim Wolak wrote: > > I am being asked to create a perl script to migrate AD accounts from one > machine to another and also migrate their files and directory > structure. Is there any good web sites I can take a look for some > example scripts or any good books? Thanks in advance. >

RE: 'format' puzzle

2005-04-14 Thread Sam
Thanks. Was right there in the manual... -Sam --- "Moon, John" <[EMAIL PROTECTED]> wrote: > Subject: 'format' puzzle > > How can I create a perl 'format' string that begins with a comment (#)? > > Eg. > > format STDOUT_TOP = > # Field1 Field2 > @<< @||| @||| > . > > > If I try '\#'

Re: Operation `eq': no method

2005-04-14 Thread Stephen Day
On Wednesday 13 April 2005 6:30 pm, JupiterHost.Net wrote: > Anish Kumar K wrote: > > Hi All > > Hello, > > > The code gives strange error > > > > $subject = I get some value from the function > > > > if ($subject eq '' || !defined $subject) > > { > > Some operation > > } > > > > Operati

Mailman vs. Dada Mail, which is better?

2005-04-14 Thread Paul Plamondon
Perl Friends, I have been charged with choosing a group email listserv application for announcements from a group I have been volunteering with during the past several years. The names Mailman and Dada Mail have risen to the top of the list, so to speak. Now, I am interested in getting a first

Re: Passing command line arguments

2005-04-14 Thread Stephen Day
On Wednesday 13 April 2005 11:12 pm, Bret Goodfellow wrote: > I have a script that is reading input from ARGV. The script is being > passed a file name as follows: > > datefile.pl c:\program files\IBM\SQLLIB\DB2\db2diag.log You could paste the two arguments together in perl, add a space between t

Re: import() functions from another module

2005-04-14 Thread M. Kristall
Jay Savage wrote: [snip] But think a little bit about the convoluted namespace you created to get that function in there. Think also about this: why have you put this code into a module? So you can reuse it, presumably. Or at least that's the assumption I'm working with. Maybe you're even goin

Re: import() functions from another module

2005-04-14 Thread Jay Savage
On 4/14/05, M. Kristall <[EMAIL PROTECTED]> wrote: > Jay Savage wrote: > [snip] > > But think a little bit about the convoluted namespace you created to > > get that function in there. Think also about this: why have you put > > this code into a module? So you can reuse it, presumably. Or at >

Re: import() functions from another module

2005-04-14 Thread JupiterHost.Net
Jay Savage wrote: [snip] But think a little bit about the convoluted namespace you created to get that function in there. Think also about this: why have you put this code into a module? So you can reuse it, presumably. Or at least that's the assumption I'm working with. Maybe you're even goin

binmode() setting FH to ascii

2005-04-14 Thread JupiterHost.Net
Howdy, http://search.cpan.org/~tjenness/File-Temp-0.16/Temp.pm#BINMODE says: "The file returned by File::Temp will have been opened in binary mode if such a mode is available. If that is not correct, use the binmode() function to change the mode of the filehandle." perldoc -f binmode doesn't see

Re: Operation `eq': no method

2005-04-14 Thread Jeff 'japhy' Pinyan
On Apr 13, Anish Kumar K said: The code gives strange error $subject = I get some value from the function Yes, and it's an object of class XML::LibXML::NodeList that doesn't have an 'eq' operator overloaded for it. Contact the author of the module, or try this work-around: if ("$subject" eq '

Re: binmode() setting FH to ascii

2005-04-14 Thread John W. Krahn
JupiterHost.Net wrote: Howdy, Hello, http://search.cpan.org/~tjenness/File-Temp-0.16/Temp.pm#BINMODE says: "The file returned by File::Temp will have been opened in binary mode if such a mode is available. If that is not correct, use the binmode() function to change the mode of the filehandle."

Re: Operation `eq': no method

2005-04-14 Thread Jeff 'japhy' Pinyan
On Apr 14, Stephen Day said: bash-2.05b$ perl -e 'if ($subject eq '' || !defined $subject) {print "no subject\n";}' syntax error at -e line 1, near "eq ||" Execution of -e aborted due to compilation errors. It seems '' is not the same as "". Any idea why? Because you used '...' to send the string

Re: Passing command line arguments

2005-04-14 Thread John W. Krahn
Stephen Day wrote: On Wednesday 13 April 2005 11:12 pm, Bret Goodfellow wrote: I have a script that is reading input from ARGV. The script is being passed a file name as follows: datefile.pl c:\program files\IBM\SQLLIB\DB2\db2diag.log You could paste the two arguments together in perl, add a space

Re: Operation `eq': no method

2005-04-14 Thread Jeff 'japhy' Pinyan
On Apr 14, Jeff 'japhy' Pinyan said: On Apr 13, Anish Kumar K said: The code gives strange error $subject = I get some value from the function Yes, and it's an object of class XML::LibXML::NodeList that doesn't have an 'eq' operator overloaded for it. Contact the author of the module, or try thi

Re: import() functions from another module

2005-04-14 Thread Jay Savage
On 4/14/05, JupiterHost.Net <[EMAIL PROTECTED]> wrote: > >>Jay Savage wrote: > >>[snip] > >> > >>>But think a little bit about the convoluted namespace you created to > >>>get that function in there. Think also about this: why have you put > >>>this code into a module? So you can reuse it, presu

Re: Passing command line arguments

2005-04-14 Thread Stephen Day
On Friday 15 April 2005 12:18 am, John W. Krahn wrote: > >>datefile.pl c:\program files\IBM\SQLLIB\DB2\db2diag.log > > > > You could paste the two arguments together in perl, add > > a space between them, and use that as the filename. > > What if there are two or more spaces? A TAB character? Th

Re: Passing command line arguments

2005-04-14 Thread Jay Savage
On 4/13/05, Bret Goodfellow <[EMAIL PROTECTED]> wrote: > I have a script that is reading input from ARGV. The script is being > passed a file name as follows: > > datefile.pl c:\program files\IBM\SQLLIB\DB2\db2diag.log > > The problem I am running into is that the space is not recognized in the

Re: import() functions from another module

2005-04-14 Thread JupiterHost.Net
I second that, but I thought regex != m// was an important point. If M is uncertain about where regexes can be used, I'm happy to help him out ;) cool :) -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: binmode() setting FH to ascii

2005-04-14 Thread JupiterHost.Net
John W. Krahn wrote: JupiterHost.Net wrote: Howdy, Hello, http://search.cpan.org/~tjenness/File-Temp-0.16/Temp.pm#BINMODE says: "The file returned by File::Temp will have been opened in binary mode if such a mode is available. If that is not correct, use the binmode() function to change the mod

Re: binmode() setting FH to ascii

2005-04-14 Thread John W. Krahn
JupiterHost.Net wrote: John W. Krahn wrote: JupiterHost.Net wrote: http://search.cpan.org/~tjenness/File-Temp-0.16/Temp.pm#BINMODE says: "The file returned by File::Temp will have been opened in binary mode if such a mode is available. If that is not correct, use the binmode() function to change

Creating reports ??

2005-04-14 Thread Michael Gale
Hello, I am currently googling for this but ... I want to know what people think or have used to create reports in perl. Maybe creating some kind of graph or an excell report ? Thanks. Michael -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Formatted output - like a html table ?

2005-04-14 Thread Michael Gale
Hello, In perl, is there a way to produce a formatted output much like in html you can create a table to produce the output ? I have tried using tabs, but it gets messy :( Michael -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

RE: Formatted output - like a html table ?

2005-04-14 Thread Charles K. Clarkson
Michael Gale wrote: : In perl, is there a way to produce a formatted output much : like in html you can create a table to produce the output? : : I have tried using tabs, but it gets messy :( Read 'perlform' or type 'perldoc perlform' from the command line.

Re: Formatted output - like a html table ?

2005-04-14 Thread Chris Devers
On Thu, 14 Apr 2005, Michael Gale wrote: > In perl, is there a way to produce a formatted output much like > in html you can create a table to produce the output ? > > I have tried using tabs, but it gets messy :( Yes, lots of ways. Perl has a big old reporting framework that goes back

Re: Formatted output - like a html table ?

2005-04-14 Thread Michael Gale
Well it should be OS independent and ideally in plain ASCII. Currently I am reading up on the Template Toolkit. Michael Chris Devers wrote: On Thu, 14 Apr 2005, Michael Gale wrote: In perl, is there a way to produce a formatted output much like in html you can create a table to produce the out

Re: Creating reports ??

2005-04-14 Thread Chris Devers
On Thu, 14 Apr 2005, Michael Gale wrote: > I am currently googling for this but ... I want to know what > people think or have used to create reports in perl. Maybe creating > some kind of graph or an excel report ? Lots of things, depending on the specific needs. The GD::Graph module h

Re: what are utf8 barewords.?

2005-04-14 Thread Rajarshi Das
In a script testing barewords, the character 'tau' displays when opened using vi editor on linux. OTOH, the same character doesnt display on z/OS and shows as ^69^22 in the vi editor. The failing line in the script is : %hash = (^69^22 => 123) Perl (5.8.6) complains when it reads thus : "Unr

Anyone using AJAX

2005-04-14 Thread Ramprasad A Padmanabhan
Hi, I am trying to learn using Ajax instead of form-oriented perl-cgi. ( fascinated with gmail :-) ) I have already started with CPAN modules Catalyst::Plugin::Ajax and HTML::Ajax. Do we have any good documenation / tool that can help me thanks Ram --