Re: Mail Send problems 1.6 CVS

2001-07-05 Thread David Monarres
I have had the same two problems with 1.16 and cvs (same day). The problem with sending mail seemed to be solved when I ran my MTA as a deamon, not through inetd. (do not know if that will help) The address thing I really haven't found a work around for. David Monarres <[EMAIL PROTECTED]> On Thu,

RE: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Notabene
Thanks all! Jeff: Your answer was the one I needed. (duh! I was so tangled in my own shorts that I forgot to mention the web page connection -- good catch. ) Steve: While I had tried your solution I wasn't seeing it since my test rig was printing to a web page -- *NOT* doing straight Perl print

RE: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Notabene
Thanks all! Jeff: Your answer was the one I needed. (duh! I was so tangled in my own shorts that I forgot to mention the web page connection -- good catch. ) Steve: While I had tried your solution I wasn't seeing it since my test rig was printing to a web page -- *NOT* doing straight Perl print

Re: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Brett W. McCoy
On Fri, 6 Jul 2001, Notabene wrote: > Okay, I surrender...what's the trick to assigning the greater-than (<) and > the less-than (>) symbols, as characters, to a variable without triggering > all sorts of unwanted "Perlish" behavior? What sorts of Perlish behavior are you seeing? You should be

RE: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Steve Howard
Ok, it's getting late. you have to use double quotes. $target = $var1."\<".$var2."\>"; Sorry, Steve H. -Original Message- From: Notabene [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 05, 2001 11:36 PM To: Perl Beginners Subject: Assigning '<' & '>' as chars to a variable Okay, I su

Re: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 6, Notabene said: > $var1 = 'This is text '; > $var2 = 'This is more text'; > $target = $var1.'<'.$var2.'>'; The more common technique is $target = "$var1<$var>"; > This is text > >I've tried "escaping" each of the two symbols but with no luck -- so what's

RE: Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Steve Howard
Escape the characters. $target = $var1.'\<'.$var2.'\>'; See if those back slashes get you what you want to see. Steve H. -Original Message- From: Notabene [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 05, 2001 11:36 PM To: Perl Beginners Subject: Assigning '<' & '>' as chars to a vari

Assigning '<' & '>' as chars to a variable

2001-07-05 Thread Notabene
Okay, I surrender...what's the trick to assigning the greater-than (<) and the less-than (>) symbols, as characters, to a variable without triggering all sorts of unwanted "Perlish" behavior? I want to do something on the order of: $var1 = 'This is text '; $var2 = 'This is mo

SQL - Multiple Updates ?

2001-07-05 Thread Rajeev Rumale
Greetings !. I have some problem with executing a SQL update statement while updating multiple records at a time. I have tried different ways but it is udating one a single (first) record. The same sql statement works perfectly when run directly on the MY SQL prompt. The code i have used are

SQL - Multiple Updates ?

2001-07-05 Thread Rajeev Rumale
Greetings !. I have some problem with executing a SQL update statement while updating multiple records at a time. I have tried different ways but it is udating one a single (first) record. The same sql statement works perfectly when run directly on the MY SQL prompt. The code i have used are

RE: -d & other file tests

2001-07-05 Thread Wagner-David
You are passing the source diretory and file, yet when doing the test you are only doing the source file and not combining the directory and file. Without seeing what you are passing, this would be my first guess. I say this becuase you always pring the two together when you print. Wags ;

Re: -d & other file tests

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 5, Adam Theo said: >sub check_source { > my($source_dir, $source_file) = @_; > print("Checking $source_dir/$source_file.\n"); > if ($source_file =~ /^\./) { > print("Can't open file '$source_dir/$source_file': > System file.\n"); > } > elsif (-d $source_fi

-d & other file tests

2001-07-05 Thread Adam Theo
Hello, Adam Theo here; i was wondering if there is something i must declare to use file tests such as -d and -e? i have code which i am working on, and i need to check to see if a file is a directory. if it is, i run a subroutine. i recall having used file tests before, and successfully. i do

RE: creating columns on the fly

2001-07-05 Thread Steve Howard
It's irrelevant where the damon (service) is running. Either method will work remotely, or on the local machine. It only depends on what you connect to. Yes, you can do this, and in fact I do it quite frequently. Usually, I make my scripts to read an ini file or some similar configuration mechanis

Absolute Path

2001-07-05 Thread SAWMaster
Hi group! Little bit of background. I made a perl cgi that scans a directory for files and auto generates a html page with hyperlinks to download whatever files are in the directory. I don't know if there's an easier way to do this than what I did (built it from scratch) but I'm doing this t

cannot run program compiled with perlcc

2001-07-05 Thread Jay Anantharaman
I cannot run the following program compiled with perlcc (seems to be a problem with IO.so not getting properly loaded?) Wonder why? How can it be fixed? Thanks! -Jay #!/usr/local/bin/perl -w use IO::File; $fh = new IO::File; if ( $#ARGV < 0 ) { $fh->fdopen(fileno(STDIN),"r"); } else {

RE: creating columns on the fly

2001-07-05 Thread Steve Howard
Two ways you can do it that I can give an example of. One is to query the system catalogue directly embedding this: SELECT name FROM syscolumns WHERE id = object_id('') (of course, substituting the table name in the appropriate place). or, if you are using DBI, you can pull a full list of colu

Re: I did it!!!

2001-07-05 Thread K.L. Hayes
Hello Newbie, And let us not forget to scold you on your non-use of "strict". The use of it in this list will help avoid future flames & find errors in longer, more complex scripts. I'll demonstrate the use of it, & include the tips posted thus far... #!c:/perl/bin/perl -w use strict; my $num

Re: Text file parsing - one chunk v char by char

2001-07-05 Thread Mike Breeze
Very nice! I love Perl:) Cheers Ken, Breezy Ken wrote: > $/ = "¬"; > > Then while() will only bring in each record. > > - Original Message - > From: "Mike Breeze" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Thursday, July 05, 2001 1:23 PM > Subject: Text file parsing - one ch

Re: I did it!!!

2001-07-05 Thread Chas Owens
On 05 Jul 2001 16:02:40 -0500, Humberto Varela wrote: > you have an error in your syntax: > > > >print STDOUT "The result you ignorant fool is: $result\n"; > > should be: > > print STDOUT "The result, you ignorant fool, is: $result\n"; > > commas help emphasize that "pause" in the print state

Re: I did it!!!

2001-07-05 Thread Humberto Varela
you have an error in your syntax: >print STDOUT "The result you ignorant fool is: $result\n"; should be: print STDOUT "The result, you ignorant fool, is: $result\n"; commas help emphasize that "pause" in the print statement. : )

I did it!!!

2001-07-05 Thread Customer Service
I’m sure I could get flamed for this, but I just successfully wrote my first program! Yaaahhh! ## perl #!c:/perl/bin/perl -w print STDOUT "Enter a number: "; chop($number = ); print STDOUT "Enter a multiplier: "; chop($mult = ); $result = $number * $mult; print STDOUT

RE: creating columns on the fly

2001-07-05 Thread Chas Owens
DBD::Sybase is reported to work. You might also try DBD::ODBC. On 05 Jul 2001 12:58:23 -0700, eric wang wrote: > Thanks for the tip, > But what if I am using Microsoft SQL server 7? > is there a way to do this? > eric > > -Original Message- > From: dave hoover [mailto:[EMAIL PROTECTED]]

Perl & Outlook/Exchange

2001-07-05 Thread Gross, Stephan
I'd like to write a Perl application that will tell me how many messages are sitting in an Exchange mailbox. Implementations of both POP3 and IMAP can query a mailbox given the username and password. The problem is that I have several mailboxes all using the same user account. Outlook can do th

RE: PLaying with CGI's

2001-07-05 Thread Ryan Ware
>Can you run a web browser under Linux? Yes >I don't have any experience w/ Linux. Am I over my head? It is not all point and click and forget about it, but it is much more powerful and stable. I would recommend Mandrake if you've never used linux before. You can download it free from http:

DBI and Oracle 8I

2001-07-05 Thread Conrad, Bill (ThomasTech)
Hi All I don't know if this is the right place to ask this but here goes. Please direct me to other lists if appropriate. I would like to use Perl to access are Oracle 8I version 817 database on Solaris 2.6. 1) Do the current DBI packages support this? 2) If so,

RE: PLaying with CGI's

2001-07-05 Thread Canavan, John
Nathan, I run Netscape on my Linux box at home. (Or at least I did until I overclocked my system by too much and fried it). I haven't run Perl on Wintel systems yet, but am in the process of trying it. I learned most of what I needed to know from "Linux for Dummies". You'll probably get a lot o

Re: Redefining a Subroutine

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 5, [EMAIL PROTECTED] said: >I need to redefine a subroutine from one package to a subroutine from >another. > >This code works and does what I want it to, however I need to write it so >it isn't hard coded. The posible necessary escapes, evals, single quotes >and double quotes make me wooz

Re[2]: Parent and Current Directories

2001-07-05 Thread Maxim Berlin
Hello SAWMaster, Thursday, July 05, 2001, Maxim Berlin <[EMAIL PROTECTED]> wrote: S>> I'm trying to list all files in a directory EXCEPT the current and S>> the parent directories. S>> ie. S>> . S>> .. S>> file1 S>> file2 S>> file3 S>> Is not what I want. I only want: S>> file1 S>> file2 S>

PLaying with CGI's

2001-07-05 Thread Customer Service
Roger G. Romeril replied to an email about test sites for cgi scripts. He mentioned that instead, it would be better to get a stripped down pc and load Linux, perl, and apache and play with that. Well, I decided to do just that. While the suggestion wasn’t specifically aimed at me, I thought th

Re: Parent and Current Directories

2001-07-05 Thread Paul Johnson
On Thu, Jul 05, 2001 at 02:43:01PM -0500, SAWMaster wrote: > Hello group! > > I'm trying to list all files in a directory EXCEPT the current and the parent >directories. > > I thought I had the right code, but I don't. > > while($i < ($#filelist)) > { > if ((@filelist[$i] ne '.') || (@file

Re: Parent and Current Directories

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 5, SAWMaster said: >while($i < ($#filelist)) >{ >if ((@filelist[$i] ne '.') || (@filelist[$i] ne '..')) >{ >print @filelist[$i]; >print "\n"; >$i++; >} >} The chief problem is your logic. if ($f ne '.' || $f ne '..') { print $f; } When '.' get

Redefining a Subroutine

2001-07-05 Thread JCervoni
I need to redefine a subroutine from one package to a subroutine from another. This code works and does what I want it to, however I need to write it so it isn't hard coded. The posible necessary escapes, evals, single quotes and double quotes make me woozy. # WORKS # und

Re: Parent and Current Directories

2001-07-05 Thread Maxim Berlin
Hello SAWMaster, Thursday, July 05, 2001, SAWMaster <[EMAIL PROTECTED]> wrote: S> Hello group! S> I'm trying to list all files in a directory EXCEPT the current and S> the parent directories. S> ie. S> . S> .. S> file1 S> file2 S> file3 S> Is not what I want. I only want: S> file1 S> file

RE: creating columns on the fly

2001-07-05 Thread eric wang
Thanks for the tip, But what if I am using Microsoft SQL server 7? is there a way to do this? eric -Original Message- From: dave hoover [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 05, 2001 12:43 PM To: Eric Wang; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: creating columns on

Parent and Current Directories

2001-07-05 Thread SAWMaster
Hello group! I'm trying to list all files in a directory EXCEPT the current and the parent directories. ie. . .. file1 file2 file3 Is not what I want. I only want: file1 file2 file3 I thought I had the right code, but I don't. while($i < ($#filelist)) { if ((@filelist[$i] ne '.') || (

Re[2]: How to check it a $Var is empty

2001-07-05 Thread Tim Musson
Hey Jeff & Others, Thursday, July 05, 2001, 2:04:17 PM, my MUA believes you used (X-Mailer not set) to write: Thanks for the tip (don't my SOMETHING if CONDITION;). I got the same response from 2 people. Is there a reason I should pick one solution over the other? Or is this another case of T

Re: creating columns on the fly

2001-07-05 Thread dave hoover
Eric Wang wrote: [snip] > First, I decided that I will need to generate the > SQL statements inside > the perl script. (i.e. print SQL "insert... > blah.."). If you use DBI, this is no problem, in fact, it's expected. You will probably call $sth->execute(SQL_HERE). You can plug in a previousl

Re: Text file parsing - one chunk v char by char

2001-07-05 Thread Ken
$/ = "¬"; Then while() will only bring in each record. - Original Message - From: "Mike Breeze" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, July 05, 2001 1:23 PM Subject: Text file parsing - one chunk v char by char > Hi there, > > I'm writing some code that has to pa

Re: Text file parsing - one chunk v char by char

2001-07-05 Thread Chas Owens
If "¬" is the record seperator then use the record seperator variable ($/) to get the individual records: {#create a new scope to prevent changes from effecting everthing else local ($/) = "¬"; while () { chomp; #get rid of "¬" on the end; do_someth

Text file parsing - one chunk v char by char

2001-07-05 Thread Mike Breeze
Hi there, I'm writing some code that has to parse a text file containing a series of records. The records are a direct export from a third party DB and are delimited by the "¬" char (I hope that comes out on all your email clients but I guess it doesn't really matter. What bothers me is that the

Re: referncing hashes of array references

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 5, Bob Mangold said: >print ${${$hashREF}{'foo'}}[1]; I posted earlier this week that $$ref[$idx] (and ${$ref}[$idx] too) and $ref->[$idx] are the same. So... $$hashref{foo} is $hashref->{foo} and then ${ $hashref->{foo} }[1] is $hashref->{foo}->[1] which can be s

Re: referncing hashes of array references

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, Bob Mangold wrote: > if I have a hash that contains array refs as its values and I create a > reference for it, what are the different ways that i can access the information > in the array? > > for example. > > my %hash; > my @array = ('red','white','blue'); > $hash{'foo'} = \

referncing hashes of array references

2001-07-05 Thread Bob Mangold
if I have a hash that contains array refs as its values and I create a reference for it, what are the different ways that i can access the information in the array? for example. my %hash; my @array = ('red','white','blue'); $hash{'foo'} = \@array; my $hashREF = \%hash; print ${${$hashREF}{'foo'}

Re: FW: Optional Variables

2001-07-05 Thread Chas Owens
Oops, sorry I got tied up here and forgot I was going to send you more info. Basicly what you need to do is this: my $query = " select this, that from table where constant_where_clause_stuff = other constant_stuff "; $option = @ARGV ? " and filename = $AR

Re: modules & path to perl

2001-07-05 Thread Peter Scott
At 02:03 PM 7/5/01 -0400, David Gilden wrote: > > perldoc CPAN and look for the autobundle command. You'll have to define > > your own personal CPAN directory first, but this is the "official" > > way. Dirtier way: > > > > find `perl -e 'print "@INC"'` -name "*.pm" -print > > > >Got a long list

Re: How to check it a $Var is empty

2001-07-05 Thread Jeff 'japhy' Pinyan
On Jul 5, Tim Musson said: >I want to split to @Group only if the 3rd element of @Line has data. >It works, but I get an error (Use of uninitialized value in split) >using -w, strict, and diagnostics. Should I be doing this differently? > >while (<>) { chomp; >my @Line = split(/,/); > >

Re: Re[2]: How to check it a $Var is empty

2001-07-05 Thread David M. Lloyd
On Thu, 5 Jul 2001, Tim Musson wrote: > CO> WAG: try > CO> my @Group = split(/_/, $Line[2]) if (defined($Line[2])); > > Thanks, that did it. I should just listen to myself talk sometimes. I > was just saying to a coworker, "I only want to split if $Line[2] is > defined"! BEWARE of this constru

Re[2]: How to check it a $Var is empty

2001-07-05 Thread Tim Musson
Hey Chas, Thursday, July 05, 2001, 1:16:05 PM, my MUA believes you used Evolution/0.10.99 (Preview Release) to write: >> I want to split to @Group only if the 3rd element of @Line has data. >> I would like to put nothing in $Group[-1] if $Line[2] is empty. >> >> while (<>) { chomp; >> my @

perl and Dial-up Networking.

2001-07-05 Thread Johnathan Thibodeau
Does anybody know how, if possible, I could get access to Dial-up Networking settings in WIndows? I need to make a set-up CD for the ISP I work for, and I want to use perl for compatability reasons (plus I don't like VB). I suppose this question could extend to any Mac people out there aswell, wi

Re: FW: Optional Variables

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, Kim Green wrote: > I don't know how or where to put & how to use this $option. > What if my Default value is a sql statement? Can I just include the name > of the file handle between the brackets? You can do something like my $option = @ARGV ? shift : 'SELECT * FROM my_table

FW: Optional Variables

2001-07-05 Thread Kim Green
I don't know how or where to put & how to use this $option. What if my Default value is a sql statement? Can I just include the name of the file handle between the brackets? -Original Message- From: Brett W. McCoy [mailto:[EMAIL PROTECTED]] Sent: Friday, June 29, 2001 6:40 PM To: M.W

Weekly list FAQ posting

2001-07-05 Thread casey
NAME beginners-faq - FAQ for the beginners mailing list 1 - Administriva 1.1 - I'm not subscribed - how do I subscribe? Send mail to <[EMAIL PROTECTED]> You can also specify your subscription email address by sending email to (assuming [EMAIL PROTECTED] is your email address)

Re: modules & path to perl

2001-07-05 Thread Peter J. Scott
At 01:29 PM 7/5/01 -0400, David Gilden wrote: >How do I list what my ISP has on there server in terms of Modules? perldoc CPAN and look for the autobundle command. You'll have to define your own personal CPAN directory first, but this is the "official" way. Dirtier way: find `perl -e 'print

Re: modules & path to perl

2001-07-05 Thread Tyler Longren
do a 'which perl' at the command line to get the location of perl. Not sure about the modules. To get the version of perl, do 'perl --version' at the command line. Tyler - Original Message - From: "David Gilden" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, July 05, 2001 1

creating columns on the fly

2001-07-05 Thread Eric Wang
Hi guys, I am writing a perl script that will take some command prompt parameters and linking it with a SQL server database. I sort of have an idea on how to do it. But need you guys to give me some directions as to which way is the best. First, I decided that I will need to generate the SQL s

modules & path to perl

2001-07-05 Thread David Gilden
How do I list what my ISP has on there server in terms of Modules? And what is the command (at the command line) to tell me what version The server has on it / and or the path to perl. Thanks Dave G. Looking for Web Talent, You found it! portfolio: w

Re: How to check it a $Var is empty

2001-07-05 Thread Chas Owens
On 05 Jul 2001 13:01:33 -0400, Tim Musson wrote: > perlers, > > I want to split to @Group only if the 3rd element of @Line has data. > It works, but I get an error (Use of uninitialized value in split) > using -w, strict, and diagnostics. Should I be doing this differently? > > I run this with a

Re: Confused

2001-07-05 Thread Peter J. Scott
At 08:41 PM 7/4/01 -0500, RL Autry wrote: >A friend of mine sent me a file to write > to help get me started on programming Perl. >So I did (in notepad): > >#!/usr/bin/perl -w >use strict; >while (<>) { >if ( /book/i or /bk/i) { >print; >} > >When I run it in my dos window -- > I get an error m

Re: string position

2001-07-05 Thread Ken
Oh oh oh! I want to try! use strict; my( $var, $long_var ); $var = '123456'; $long_var = ' ' x 19 . $var; print "$long_var\n"; *in the distance you hear the sounds of someone beating something with a stick* - Original Message - From: "F.H" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> S

How to check it a $Var is empty

2001-07-05 Thread Tim Musson
perlers, I want to split to @Group only if the 3rd element of @Line has data. It works, but I get an error (Use of uninitialized value in split) using -w, strict, and diagnostics. Should I be doing this differently? I run this with a filename parm, and the file contains: uid1,cn 1,ua_bit_essd ui

Re: string position

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, Brett W. McCoy wrote: > On Thu, 5 Jul 2001, F.H wrote: > > > I'd like to be able to print a string at a specific location . Is there any >function that does that. > > $test = "abcd'; > > I want to print $test at position 20-25. > > I appreciate if someone can help > > You wil

Re: string position

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, F.H wrote: > I meant, counting characters from left to right, $test will occupy charcater >position 20 through 25, the print out will look like this. > >,abcd , > > there are other string variables before and after that $test of course. Greg Oh, you shou

Re: string position

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, F.H wrote: > I'd like to be able to print a string at a specific location . Is there any function >that does that. > $test = "abcd'; > I want to print $test at position 20-25. > I appreciate if someone can help You will need something like the Curses module that will let you

Re: string position

2001-07-05 Thread Chas Owens
On 05 Jul 2001 11:31:32 -0400, F.H wrote: > Hi, > I'd like to be able to print a string at a specific location . Is there any function >that does that. > $test = "abcd'; > I want to print $test at position 20-25. > I appreciate if someone can help > > Thanks > I.S >

New to Perl

2001-07-05 Thread Akens, Anthony
Hello, I'm completely new to perl, but have a good deal of experience with c / c++. I'm wondering if there are any good websites that will give me a basic introduction to programming in perl (data structures, etc). I've found references to a few books, but would like to gather some basic info fro

RE: Match Keys in two Hashes - THANKS!

2001-07-05 Thread Perl Beginner
Just a note to say: THANK YOU ALL VERY MUCH FOR YOUR HELP!!! :o) -Original Message- At 01:08 PM 7/2/01 -0500, Perl Beginner wrote: >Hello, > >I'm your typical beginner who is kind of stuck. Here is the problem: > >I have two hashes, each has ~40,000 key/value pairs. I need to find whic

Re: string position

2001-07-05 Thread F.H
I meant, counting characters from left to right, $test will occupy charcater position 20 through 25, the print out will look like this. ,abcd , there are other string variables before and after that $test of course. Greg Meckes <[EMAIL PROTECTED]> wrote: > > You can try:

Re: string position

2001-07-05 Thread Greg Meckes
You can try: $test = "abcd"; $test = sprintf "%24s" , $test; Greg __ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail http://personal.mail.yahoo.com/

Re: string position

2001-07-05 Thread Chas Owens
On 05 Jul 2001 11:31:32 -0400, F.H wrote: > Hi, > I'd like to be able to print a string at a specific location . Is there any function >that does that. > $test = "abcd'; > I want to print $test at position 20-25. > I appreciate if someone can help > > Thanks > I.S >

Re: progress Bar

2001-07-05 Thread Jorge Goncalvez
- Begin Forwarded Message - Delivered-To: [EMAIL PROTECTED] From: Jorge Goncalvez <[EMAIL PROTECTED]> Subject: Re: progress Bar I have seen the widget demo for using TK::progressBar but it doesn't help me very munch because I don't know how to make my progress bar go

string position

2001-07-05 Thread F.H
Hi, I'd like to be able to print a string at a specific location . Is there any function that does that. $test = "abcd'; I want to print $test at position 20-25. I appreciate if someone can help Thanks I.S __ Get your own FREE, per

http, ftp, and perl

2001-07-05 Thread S.J.
I am trying to write a program that will allow a Perl program running from a windows nt system to access ftp and http files. Which modules/formats would I need to use to do this?

RE: $ARGV

2001-07-05 Thread Chas Owens
$ARGV[0] and $ARGV[1] are not file handles. They are elements of commandline argument array @ARGV. ARGV is a special file handle that holds the current file being read by an empty <> operator. $ARGV is another special variable that holds the name of the file currently being read by an empty <>

RE: $ARGV

2001-07-05 Thread Govinderjit Dhinsa
I have tried to find out in full detail about the file handle $ARGV and only got the basics. Could any one please explain the $ARGV in more detail, e.g. how to put a input file into the $ARGV, if the input file was constantly changing! The File in may program:

Re: simple regexp

2001-07-05 Thread Mario Todorow
Try this one line command perl -ne ' print "$1\n" if /\s(\S+\.\S+\.\S+\.\S+)\s/' file Cordially Mario

EXPORT and EXPORT_OK

2001-07-05 Thread JCervoni
Is it possible to change @EXPORT during runtime? I'm trying to import subroutines in the following manner: - I have a file called DBLib.pm which imports a file "DefaultLib.pm" via a "use". DBLib.pm ### package DBLib.pm use strict ; require Exporter ; use DefaultLib ; use vars q

Re:Progress bar

2001-07-05 Thread Jorge Goncalvez
- Begin Forwarded Message - Date: Thu, 5 Jul 2001 16:15:05 +0200 (MEST) From: Jorge Goncalvez Subject: Re:Progress bar To: [EMAIL PROTECTED] Mime-Version: 1.0 Content-MD5: EFvZDRoA/ttGIJBKvpTZIQ== - Begin Forwarded Message - Delivered-To: [EMAI

Re:number of records

2001-07-05 Thread Brett W. McCoy
On Thu, 5 Jul 2001, Jorge Goncalvez wrote: > I have the following : > > @drives = Win32::DriveInfo::DrivesInUse(); > > How can I get the number of element in the array @drives? my $num_drives = @drives; An array in scalar context gives the number of elements. -- Brett

Re: Using getopt::std return hash with value of 1 rather than argument

2001-07-05 Thread Craig Moynes/Markham/IBM
>The perldoc for getopt::std states: >Hash keys will be x (where x is the switch name) with key >values the value of the argument or 1 if no argument is >specified This is true for getopt, but not getopts. Getopts puts the parameter in the hash table (I am working on 5.005_03 built for aix ) per

Using getopt::std return hash with value of 1 rather than argument

2001-07-05 Thread charles
> Clean this up as: > if ($option{n}) { > $domain = $option{n} > add(); > } > > Don't use ARGV once you have used getopt (or getopts). The hash you > specify to the option getter > creates the keys as the flags and the values as the associated parameter. > > #if -f, then set $path > if

RE: \r

2001-07-05 Thread Aaron Craig
At 14:13 05.07.2001 +0100, Govinderjit Dhinsa wrote: > What is the code please to get, after field 6; > \r (carriage return) > > I tried this, but no luck; > $fields[6] =~ s\r//; try $fields[6] =~ s/\r//; ^ |

RE: \r

2001-07-05 Thread Govinderjit Dhinsa
What is the code please to get, after field 6; \r (carriage return) I tried this, but no luck; $fields[6] =~ s\r//; Any help would be much appreciated!!! Thanks, GD # PROGRAM: #!/path/to

Re: mod_perl

2001-07-05 Thread Francisco Ho
At 01:20 PM 07/05/2001 +0530, you wrote: >Hi All > >Today I installed Indigo Perl on my system and when I tried the sample >code which came along with the installation to test mod_perl it gave an >error as "Page not found" > >I checked the following before posting >a) I found that the file exist

RE: number of records

2001-07-05 Thread Robin Lavallee (LMC)
Use it in scalar context: my $num_elements = @drives; -Robin > -Original Message- > From: Jorge Goncalvez [SMTP:[EMAIL PROTECTED]] > Sent: Thursday, July 05, 2001 8:14 AM > To: [EMAIL PROTECTED] > Subject: Re:number of records > > I have the following : > > @drives = Win32::Dr

Executing Script from Sendmail

2001-07-05 Thread David Rankin
Hello, I am trying to write a script that is run by piping email to it from an alias. The script is running on Red Hat Linux 7.0, and the MTA's sendmail. I'm also using smrsh. I'm not sure if the problem is with the script or something else, but here's the code I'm using (just for testing righ

Re:number of records

2001-07-05 Thread Jorge Goncalvez
I have the following : @drives = Win32::DriveInfo::DrivesInUse(); How can I get the number of element in the array @drives? $cc2-> checkbutton (-label=>$drives[0], -variable => \$A); $cc2-> checkbutton (-label=>$drives[1], -variable => \$B); $cc2-> checkbutton (-label=>$drives[2], -variable =>

RE: Windows2000

2001-07-05 Thread Conrad, Bill (ThomasTech)
I click on "reply to all" and delete the individuals address, leaving only the address to the list. That way the individual doesn't get two e-mails. Bill Conrad -Original Message- From: RL Autry [mailto:[EMAIL PROTECTED]] Sent: Tuesday, July 03, 2001 3:45 PM To: Aaron Craig; [EMAIL PROT

RE: Regex

2001-07-05 Thread Govinderjit Dhinsa
Thank you for your time and your valuable help is much appreciated. I made the changes to the program like you suggested, however I get this error, when I run the program! ## A3 GD > perl CSV.PL; Global symbol "$line" requires e

RE: newwin function

2001-07-05 Thread Sally
I can't help any more I'm afraid, hope you sort it, Regards, Sally -Original Message- From: George S Pereira [mailto:[EMAIL PROTECTED]] Sent: 05 July 2001 12:17 To: Sally Cc: [EMAIL PROTECTED] Subject: RE: newwin function Yes, but is there a workaround. maybe by changing the height o

RE: newwin function

2001-07-05 Thread George S Pereira
Yes, but is there a workaround. maybe by changing the height of each line to 1.5% of what it is now. I'm not very sure that what I'm saying is even possible.. But the Idea remains. George Savio Pereira Email : [EMAIL PROTECTED] On Thu, 5 Jul 2001, Sally wrote:

Re: Regex

2001-07-05 Thread Jos I. Boumans
Hi, the problem you have is not a bit one, so the solution is fairly simple.. however, there are some issues you need to concider in your script, so let me show you a few pointers: ### USE STRICT AND -w I can not stress that enough!!! ### #!/path/to/perl -w use strict; ### use CAPS for filehan

RE: Regex

2001-07-05 Thread Govinderjit Dhinsa
Hi, I have been asked to write a perl script, to Delete 1 field in a input file and then print to a output file! What I need to delete from the file is: Field [3] Can any body please suggest what else needs to be added to the script that I wrote below to do this task pleas

RE: newwin function

2001-07-05 Thread Sally
Surely if in the man pages the parameters are integers then only integers can be used? -Original Message- From: George S Pereira [mailto:[EMAIL PROTECTED]] Sent: 05 July 2001 10:16 To: [EMAIL PROTECTED] Subject: newwin function Hi All, I'm using a Curses kit called CDK (Curse

Re:Win32::Driveinfo

2001-07-05 Thread Jorge Goncalvez
Hi, I try to use Win32::DriveInfo and I installed Win32-Api via ppm and when I want to use it I 've got the following error can't locate Win32/DriveInfo.pm in @INC. Thanks.

newwin function

2001-07-05 Thread George S Pereira
Hi All, I'm using a Curses kit called CDK (Curses Development Kit). There is a C function in one of the files which calls the system function newwin(). The parameters given are the height, width, Xpos and Ypos. newwin() creates a window of the given height and width.

Re:dynamic menu

2001-07-05 Thread Jorge Goncalvez
Hi, I would like to do a dynamic menu in Perl Tk ie I would like to display all available drive in my computer dynamically because now it has been hard written. (A,B,C,D,E,F,G,H,I) How I can do this. My code: sub makemenu{ my $menubar = $mw->Menu(-type => 'menubar', -re

Re: RE:regular expression

2001-07-05 Thread Me
> Hi, I have the following string into a file: > > LOG_INFO : cpcdos23.col.bsf.alcatel.fr: read request for /bootp/popo.txt: > success. > > And I have this code: > > my ($f)=@_; > $thistime=(stat($f))[9]; > return if ($thistime == $mtime); > > $mtime=$thistime; > my $dummy; > open (FILE, $f) || wa

RE:regular expression

2001-07-05 Thread Jorge Goncalvez
Hi, I have the following string into a file: LOG_INFO : cpcdos23.col.bsf.alcatel.fr: read request for /bootp/popo.txt: success. And I have this code: my ($f)=@_; $thistime=(stat($f))[9]; return if ($thistime == $mtime); $mtime=$thistime; my $dummy; open

mod_perl

2001-07-05 Thread Joel Divekar
Hi All Today I installed Indigo Perl on my system and when I tried the sample code which came along with the installation to test mod_perl it gave an error as "Page not found" I checked the following before posting a) I found that the file exists b) path in the html page is also correct. c) Ap

  1   2   >