Time::HiRes

2002-09-04 Thread Angerstein
Has anyone used it? How exact is it? Any experience? -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: converting a list into array

2002-09-04 Thread Dharmendra Rai
Earlier you were reading from no where. In later case you started reading using the file handle. - Get a bigger mailbox -- choose a size that fits your needs.

Re: return, wantarray, hash goodness

2002-09-04 Thread John W. Krahn
Wiggins D'Anconia wrote: > > A little background followed by a bunch of questions. > > I am working on old shoddy code written by someone else who was an > administrator not a developer, yikes, yeh I know bad place to be, but > hey they are paying me for this. > > I have a function that current

format list

2002-09-04 Thread Mandar Rahurkar
Hi, I wrote perl script so as to have a formatted list however it doesnt work.It cant take a list as its value.It has to be $variable. Does anyone know a workaround. Many Thanks Mandar format TABLE = === A

return, wantarray, hash goodness

2002-09-04 Thread Wiggins d'Anconia
A little background followed by a bunch of questions. I am working on old shoddy code written by someone else who was an administrator not a developer, yikes, yeh I know bad place to be, but hey they are paying me for this. I have a function that currently returns an array when it should be r

Re: script debug help

2002-09-04 Thread John W. Krahn
David wrote: > > John W. Krahn wrote: > > > >> $current = $line[14]; > >> $jobid[$njob++] = $current; > >> $starttime{$current} = $line[2] . " "; > >> $starttime{$current} .= $line[3] . " "; > >> $starttime{$current} .= $line[4] . " "; > >> $starttime{$current} .= $line[5] . " "; > >> $sta

A problem about Tk::Tree

2002-09-04 Thread Wang Jun
Hello... When I use following option of the TK::Tree: -- Name: browseCmd Class: BrowseCmd Switch: -browsecmd Specifies a callback to call whenever the user browses on an entry (usually by single-clicking on the entry). The callback is called with one argument

Re: Newbie question - Can smtp send attachments?

2002-09-04 Thread Tim Musson
Hey Alex, My MUA believes you used Internet Mail Service (5.5.2653.19) to write the following on Wednesday, September 4, 2002 at 2:39:07 PM. YA> Hi, YA> Having problems with just a simple test of MIME::Lite. Here is the output: YA> *

Attributes of files on SMB shares

2002-09-04 Thread Bryan Harris
Is it possible to set the hidden attribute of a file on an SMB share using perl? I've tried everything I could think of, but no dice. TIA. - Bryan -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: script debug help

2002-09-04 Thread david
your script is very hard to read. :-) if you know where the problem might be, it's better to just post the section of code that might be failing. posting the whole file with lots of log lines make it hard to read. it seems to me that you just want the log lines that contain a certain reg. ex

Perl/Tk

2002-09-04 Thread Timothy
Couple of questions regarding Perl/Tk: [1] I'm trying to get a shell command's output displayed in a listbox. open (PIPE, "${strShellCommand}|"); while ($strLine = ) { chomp $strLine; $objListBox->insert("end", "$strLine"); } close PIPE; This seems to complete the

Re: script debug help

2002-09-04 Thread Michael Fowler
On Wed, Sep 04, 2002 at 04:44:39PM -0700, david wrote: > John W. Krahn wrote: [snip] > > $starttime{$current} = join ' ', @line[2 .. 6]; > > or you could remove the need for join all together: > > $starttime{$current} = "@line[2..6]"; That doesn't really remove the join, it just makes it impl

Re: script debug help

2002-09-04 Thread david
John W. Krahn wrote: > >> $current = $line[14]; >> $jobid[$njob++] = $current; >> $starttime{$current} = $line[2] . " "; >> $starttime{$current} .= $line[3] . " "; >> $starttime{$current} .= $line[4] . " "; >> $starttime{$current} .= $line[5] . " "; >> $starttime{$current} .= $line[6]; >

Re: script debug help

2002-09-04 Thread John W. Krahn
Mike Singleton wrote: > > This script will ultimately return the values of the regex strings for > successful backup. I am stumped right now as how to proceed, as the script > seems to run without error, yet return nothing. > > == Log File = > 172.16.54.132 ssjobhnd Thu Jun 27 02:00:01 2

need help ... text boxes/form .... alphanumeric input only

2002-09-04 Thread Luinrandir Hernsen
Hallo I had to replace the pull down menues to text boxes on my order form. This means I need to filter out unwanted text. I need to make it alphanumeric only.for security reasons. I have red/bold the two lines I changed last time to eliminate all "0" "zero" orders. if you are not receiving th

Re: converting a list into array

2002-09-04 Thread Luinrandir Hernsen
Hallo I had to replace the pull down menues to text boxes on my order form. This means I need to filter out unwanted text. I need to make it alphanumeric only.for security reasons. I have red/bold the two lines I changed last time to eliminate all "0" "zero" orders. if you are not receiving th

Re: Hash of Hashes woes...

2002-09-04 Thread Greg Oliver
On Wed, 04 Sep 2002 15:21:37 -0700 "John W. Krahn" <[EMAIL PROTECTED]> wrote: > You should probably just return $newdata and assign it directly in the > foreach loop. > John > -- True, but the nature of the threads in this one, I do not get the result. One line beow in the example is: $pool->j

Re: Hash of Hashes woes...

2002-09-04 Thread John W. Krahn
Greg Oliver wrote: > > Hi, Hello, > I am writing a script that initializes a %HoHoH while iterating > through several items. This works correctly, and also retrieving > the keys/values works correctly. I then call a subroutine that > retrieves data and is SUPPOSED to update that same hash wit

Re: Extracting bits out of a string of bytes

2002-09-04 Thread John W. Krahn
Bridget Benson wrote: > > This is a response to last week's question on how to extract bits out > of a string of bytes. > > Assume $packet is a string of 8 bytes. > > To extract the second byte: > $second = unpack ('C', substr($packet, 1, 1)); You really don't need substr() here. $second = un

Re: Perl taking a long time to exit? Freeing memory?

2002-09-04 Thread Paul Johnson
On Wed, Sep 04, 2002 at 05:07:41PM +0100, Jeff AA wrote: > > > > It could be garbage collection, but it shouldn't take 2 minutes to > > free() 700MBs of data. Could be that your code is written in such > > a way that it is having to back out of lots of subroutines and > > free'in

Re: converting a list into array

2002-09-04 Thread david
[EMAIL PROTECTED] wrote: > The script gave a syntax error at > > chomp(my @data = ); that's sure going to give red flag. :-) > > However, when I tried with the following it worked - any ideas why? > chomp(my @data = ); > that's what i orginally posted but i guess my newsreader is trying to

Re: Newbie

2002-09-04 Thread david
what you can do is open the file, read it line by line and add it to a total: #!/usr/bin/perl -w use strict; #-- our total my $total = 0; #-- try open the file. if we can't, print the reason open(FILE,"fileA") || die $!; #-- read the file line by line and add it to $total. #-- normally, when

Re: converting a list into array

2002-09-04 Thread sangeeta
The script gave a syntax error at chomp(my @data = ); However, when I tried with the following it worked - any ideas why? chomp(my @data = ); On Wed, 04 Sep 2002 12:06:14 -0700 david <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > > Hi, > > > > I have a file with a list of symbols

Newbie

2002-09-04 Thread James Parsons
This is probably a very simple question for the group.but here's goes. Please keep in mind I'm just a beginner. I have the following file and I would like to add the lines in the file and get a total with a floating $ sign. fileA. 0010 0032 0043 0032 0014 0042 003

Re: Perl 5.8.0

2002-09-04 Thread Paul Johnson
On Tue, Sep 03, 2002 at 11:19:24AM -0400, Jason Frisvold wrote: > Oh, I am happy with 5.6.1 ... Use it all over the place ... But ... > Threading ... Real, honest threading? That would be something > wonderful... 5.8.0 uses a new threading model. It works well, by all accounts. > Any idea

Re: Hash of Hashes woes...

2002-09-04 Thread david
Greg Oliver wrote: > %Results = ( > $cty => { $dom => { $eng => "value"}} ); you might want to consider: my $Results; $Results->{$cty}->{$dom}->{$eng} = "value"; as that seem to be more readable. :-) > > I agree, but it isn't!!! The only other thing that could be it is th

Re: Development / Production configuration switching

2002-09-04 Thread Phil Rhodes
At 02:30 PM 9/4/2002, you wrote: >This works great as is. However, I wonder if there is a quick and easy >way to do this on a global scale. I'd like to be able to have a >"global" config file with all of the common parameters in it and then be >able to use a module to give me only the values I n

Re: Development / Production configuration switching

2002-09-04 Thread david
try use a small module to hold the servers that you need: #-- GlobalConfig.pm package GlobalConfig; use Exporter; use strict; our @ISA=qw(Exporter); our @EXPORT=qw($DEV_SERVER $PROD_SERVER); our $DEV_SERVER = 'dev.server'; our $PROD_SERVER = 'prod.server'; 1; __END__ and then you can just us

Re: Hash of Hashes woes...

2002-09-04 Thread Greg Oliver
> > # Main > > my $Results; > > this only declare a $Results scalar Sorry typo for the email! it is %Results > > # Initialized with 3 for every value > > # $Results{ $cty }{ $dom }{ $eng } = "3"; > > here, you are trying to use a %Results hash from $Results{ $cty }. > the '{ $dom }{ $eng }'

Re: Hash of Hashes woes...

2002-09-04 Thread david
Greg Oliver wrote: > Example: > > # Main > my $Results; this only declare a $Results scalar > > # Initialized with 3 for every value > # $Results{ $cty }{ $dom }{ $eng } = "3"; here, you are trying to use a %Results hash from $Results{ $cty }. the '{ $dom }{ $eng }' portion does create a has

Re: converting a list into array

2002-09-04 Thread sangeeta
Thanks a lot :) On Wed, 04 Sep 2002 12:06:14 -0700 david <[EMAIL PROTECTED]> wrote: [EMAIL PROTECTED] wrote: > Hi, > > I have a file with a list of symbols: > > AAPL > AMCO > IBM > ORCL > > I want to print like > 'AAPL','AMCO','IBM''ORCL' > > Thanks for the help > > Sangeeta you can try:

Development / Production configuration switching

2002-09-04 Thread Jason Frisvold
Since we've finally been able to get a development machine, I find myself needing a quick, efficient way of pointing the programs we write at the correct location for the different servers they need to talk to. For instance, in production we use server A for the database server. But in development

Re: converting a list into array

2002-09-04 Thread david
[EMAIL PROTECTED] wrote: > Hi, > > I have a file with a list of symbols: > > AAPL > AMCO > IBM > ORCL > > I want to print like > 'AAPL','AMCO','IBM''ORCL' > > Thanks for the help > > Sangeeta you can try: open(FOO,'foo.txt') || die $!; chomp(my @data = ); close(FOO); print "'",join("','",

Hash of Hashes woes...

2002-09-04 Thread Greg Oliver
Hi, I am writing a script that initializes a %HoHoH while iterating through several items. This works correctly, and also retrieving the keys/values works correctly. I then call a subroutine that retrieves data and is SUPPOSED to update that same hash with the results. Unfortunately, when I

Re: OT - Interesting Perl output; What is it?

2002-09-04 Thread Jeff 'japhy' Pinyan
On Sep 4, nyec said: >The program took a number sequence. For example <10-100>, reversed the digits >and calculated the difference of the original number. So the calculations >look like this: <10-01=9; 11-11=0; 12-21=9; 13-31=18; etc.>. A number subtracted from its reverse yields a multiple of 9

Re: converting a list into array

2002-09-04 Thread Bridget Benson
>Hi, > >I have a file with a list of symbols: > >AAPL >AMCO >IBM >ORCL > >I want to print like >'AAPL','AMCO','IBM''ORCL' > >Thanks for the help > >Sangeeta Maybe open (FILE, "$filename"); # READS in one line at a time ($_ contains all characters on that line) while () { print "$_, "; } >

RE: converting a list into array

2002-09-04 Thread Bob Showalter
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, September 04, 2002 2:51 PM > To: [EMAIL PROTECTED] > Subject: converting a list into array > > > Hi, > > I have a file with a list of symbols: > > AAPL > AMCO > IBM > ORCL > > I want to print

Re: converting a list into array

2002-09-04 Thread Jeff 'japhy' Pinyan
On Sep 4, [EMAIL PROTECTED] said: >AAPL >AMCO >IBM >ORCL > >I want to print like >'AAPL','AMCO','IBM''ORCL' Have you tried anything? open FILE, "tickers.txt" or die "can't read tickers.txt: $!"; chomp(my @sym = ); close FILE; Now you have @sym with the tickers. If you want to print it w

Re: OT - Interesting Perl output; What is it?

2002-09-04 Thread Kevin Meltzer
I think this is called "n - reversal of digits of n' where a(n) is a multiple of 9. A good place to find out about number sequences is: http://www.research.att.com/~njas/sequences/ Which is where I found this sequence. Cheers, Kevin On Wed, Sep 04, 2002 at 09:30:59AM -0700, nyec ([EMAIL PROTE

converting a list into array

2002-09-04 Thread sangeeta
Hi, I have a file with a list of symbols: AAPL AMCO IBM ORCL I want to print like 'AAPL','AMCO','IBM''ORCL' Thanks for the help Sangeeta -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Newbie question - Can smtp send attachments?

2002-09-04 Thread James Edward Gray II
It means that you need a "my" before your $msg variables' first use. You predeclared "use strict" promising Perl you would declare your variables before using them. "my $msg" would declare a local variable so you can use it. James On Wednesday, September 4, 2002, at 01:39 PM, Yuen, Alex wr

RE: Newbie question - Can smtp send attachments?

2002-09-04 Thread david
Alex Yuen wrote: > #!/usr/local/bin/perl -w > > use MIME::Lite; > use strict; > > $msg = MIME::Lite->new( > From =>'[EMAIL PROTECTED]', > To=>'[EMAIL PROTECTED]', > Subject =>'Testing MIME::Lite Module.', > Data =>"Successfully sent message." > ); >

RE: Newbie question - Can smtp send attachments?

2002-09-04 Thread Yuen, Alex
Hi, Having problems with just a simple test of MIME::Lite. Here is the output: ** Global symbol "$msg" requires explicit package name at mimetest.pl line 6. Global symbol "$msg"

Re: substr or anything like that

2002-09-04 Thread Jeff 'japhy' Pinyan
On Sep 4, zanardi2k2 said: >I extract data from an AS/400 table, and i am not able to get a decent >CSV format. So i have to choose a fixed-width format. Now i have to get >all values. Is there something better than: > >$var1=substr($_, 0, 10) >$var2=substr($_, 11, 16) >$var3=... Sounds like yo

Re: Building SQL statement

2002-09-04 Thread david
Mark Wildey wrote: > '$Var1','$Var2','$Var3','$Var4' etc etc if you really have something like: @DataIn = ('$Var1','$var2','$Var3','$Var4'); #-- ...etc you are telling Perl not to(because of the single quote) interpolate on $Var1, $Var2, $Var3 .. etc foreach $word (@DataIn){ print "W

RE: HELP !! displaying Associate Array value pairs

2002-09-04 Thread Nikola Janceski
love the mnemonic for $!, "What just went bang?" > -Original Message- > From: david [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, September 04, 2002 1:46 PM > To: [EMAIL PROTECTED] > Subject: Re: HELP !! displaying Associate Array value pairs > > > Quincy Ntuli wrote: > > >

Re: HELP !! displaying Associate Array value pairs

2002-09-04 Thread david
Quincy Ntuli wrote: > open(INVIN, "$sortedListing[$i]") or die "COULD NOT OPEN > $i\n"; > if the open is failing, you probably want to know why($! tells you why): open(INVIN, $sortedListing[$i]) or die "COULD NOT OPEN $i: $!\n"; david -- To unsubscribe, e-mai

RE: HELP !! displaying Associate Array value pairs

2002-09-04 Thread Bob Showalter
> -Original Message- > From: Quincy Ntuli [mailto:[EMAIL PROTECTED]] > Sent: Tuesday, September 04, 2001 1:20 PM > To: [EMAIL PROTECTED] > Subject: HELP !! displaying Associate Array value pairs > > > > greetings > > I am trying to return the value from an associate array; i do > not

Re: sorting of arrays

2002-09-04 Thread Felix Geerinckx
on Tue, 04 Sep 2001 12:15:37 GMT, Quincy Ntuli wrote: > I understand that perl desides how it stores data in an array. Perl doesn't, you do. Data in an array is indexed by an integer. You, the programmer, choses at which position you put your data: $array[0] = 0; $array[1] = 1; Or,

Re: locking a file in linux

2002-09-04 Thread david
this is still better than checking for a .swp file. some editor never uses any .swp files and doesn't even know the fact that another editor is opened and is editing the same file at the same time. what he can do is change: next unless $p->cmndline =~ /vi.*tmp\.pl/; the above line to include s

RE: sorting of arrays

2002-09-04 Thread David . Wagner
As default it assumes ascii (alphanumeric data). So if you have only numeric data then you need to change to @sorted = sort {$a <=> $b} @list; which would sort numerically if needed otherwise will sort as you want. Wags ;) -Original Message- From: Quincy Ntuli [mailto:[

HELP !! displaying Associate Array value pairs

2002-09-04 Thread Quincy Ntuli
greetings I am trying to return the value from an associate array; i do not understand what i am doing wrong. I know i made be reinventing the wheel here if you follow what i am trying to do. thanks #!/usr/bin/perl -w %theHash = (); @dbRec = (); @listing = (); @sortedListing = () ; # makin

sorting of arrays

2002-09-04 Thread Quincy Ntuli
I understand that perl desides how it stores data in an array. does it make sense for me to ... @sorted = sort @list;

RE: Perl distribution and use

2002-09-04 Thread Timothy Johnson
You can point to a network Perl install with really no problems. I used to do that. Now I use ActiveState's PerlApp, though, to create a packaged .exe file that can be distributed easily without regard to who has Perl installed and what modules they have. -Original Message- From: zanar

Perl distribution and use

2002-09-04 Thread zanardi2k2
I'm new to Perl but it seems to fit for my network administrative tools. Right now, we are using a mix of dos batch files, visual basic, c, relay and many other languages to create the tools we need. One of my favourites Perl features is the fact that since it is an interpreted language, we ca

Re: substr or anything like that

2002-09-04 Thread James Edward Gray II
If you have fixed width values, separated by spaces and with no spaces in the values, you could use the super simple: @list_of_values = split ' ', $fixed_width_line; On Wednesday, September 4, 2002, at 11:00 AM, zanardi2k2 wrote: > I started to use perl a couple of months ago in my spare time

Re: substr or anything like that

2002-09-04 Thread Felix Geerinckx
on Wed, 04 Sep 2002 16:00:06 GMT, Zanardi2k2 wrote: > Is there something better than: > > $var1=substr($_, 0, 10) > $var2=substr($_, 11, 16) > $var3=... See perldoc -f pack perldoc -f unpack If you have e.g. the following layout: my $string = "123 456 ABC"; i.

FW: Win32-Perms: Looking up local groups by SID

2002-09-04 Thread Timothy Johnson
I tried posting this to the ntadmins group, but no go so far. Does anyone on this list know how to do this? Does anyone know how to resolve a local group account by SID using Win32::Perms? It looks like you used to be able to specify the server to check on, but the 200206XX version doesn't see

Extracting bits out of a string of bytes

2002-09-04 Thread Bridget Benson
This is a response to last week's question on how to extract bits out of a string of bytes. Assume $packet is a string of 8 bytes. To extract the second byte: $second = unpack ('C', substr($packet, 1, 1)); To extract the last four bytes $last_four = unpack ('N', substr($packet, 4, 4)); To ext

OT - Interesting Perl output; What is it?

2002-09-04 Thread nyec
This is off-topic, but I wasn't able to get an answer on a few math forums, so I thought I'd pass it by the diverse Perl community. By accident my Perl program produced some output - incorrect, but interesting. I was wondering if anyone recognizes the numerical pattern or what it is called? I c

RE: Perl taking a long time to exit? Freeing memory?

2002-09-04 Thread Jeff AA
> > It could be garbage collection, but it shouldn't take 2 minutes to > free() 700MBs of data. Could be that your code is written in such > a way that it is having to back out of lots of subroutines and > free'ing things as it goes? Such as with recursion? no recursion, and on

substr or anything like that

2002-09-04 Thread zanardi2k2
I started to use perl a couple of months ago in my spare time, so i am sorry if my question is about a very simple thing. I extract data from an AS/400 table, and i am not able to get a decent CSV format. So i have to choose a fixed-width format. Now i have to get all values. Is there somethi

Re: Newbie question - Can smtp send attachments?

2002-09-04 Thread Frank Wiles
.--[ Yuen, Alex wrote (2002/09/04 at 11:16:30) ]-- | | Is it possible to send attachments using NET::SMTP? | | Will I need to use a seperate module in my script? If so, which one and how? | `- It's not really possible to d

RE: Newbie question - Can smtp send attachments?

2002-09-04 Thread Bob Showalter
> -Original Message- > From: Yuen, Alex [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, September 04, 2002 11:17 AM > To: 'Perl Beginners' > Subject: Newbie question - Can smtp send attachments? > > > Hi, > > Is it possible to send attachments using NET::SMTP? Well, yes. But SMTP doesn'

script debug help

2002-09-04 Thread Mike Singleton
This script will ultimately return the values of the regex strings for successful backup. I am stumped right now as how to proceed, as the script seems to run without error, yet return nothing. == Log File = 172.16.54.132 ssjobhnd Thu Jun 27 02:00:01 2002 SNBJH_3075J Syncsort Backup Expre

Newbie question - Can smtp send attachments?

2002-09-04 Thread Yuen, Alex
Hi, Is it possible to send attachments using NET::SMTP? Will I need to use a seperate module in my script? If so, which one and how? Thanks. Alex -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Building SQL statement

2002-09-04 Thread Mark Wildey
True beginners question…. sorry I have a MS Access database that has lots of fields in it. When I build the SQL statement to insert data retrieved from a text file, rather than build a very long SQL statement I have used a “@column = $db->FieldNames()” subroutine to build a scalar variable ( cal

RE: Newbie question on smtp...

2002-09-04 Thread Yuen, Alex
Never mind...figured it out. Stupid error with the # sign. Thanks though. Alex > -- > From: Yuen, Alex > Sent: Wednesday, September 04, 2002 10:11 AM > To: 'Perl Beginners' > Subject: Newbie question on smtp... > > I am having problems with smtp. I am trying to

Newbie question on smtp...

2002-09-04 Thread Yuen, Alex
I am having problems with smtp. I am trying to do a simple test from the documentation and can't figure out why it is not working. I get this error message: Can't call method "mail" on an undefined value at windowstest_07.pl line 10. Here is what I have.

Re: Perl taking a long time to exit? Freeing memory?

2002-09-04 Thread Frank Wiles
.--[ Jeff AA wrote (2002/09/04 at 09:34:56) ]-- | | I have a Perl script that creates a large hash, from a collection of | files. I am running Perl 5.6.1 on SMP Linux 2.4.18, top shows my process | using up to 700MB of memory (which is fine on our servers). I have | noticed thou

Re: Cookbook example (fwd)

2002-09-04 Thread Felix Geerinckx
on Thu, 05 Sep 2002 10:02:03 GMT, [EMAIL PROTECTED] (Sudarshan Raghavan) wrote: > Not sure if this mail was sent properly, my apologies if you > already have recd this. It was, as you could have found out yourself by going to (or by using a new

Re: Cookbook example (fwd)

2002-09-04 Thread Sudarshan Raghavan
Not sure if this mail was sent properly, my apologies if you already have recd this. On Tue, 3 Sep 2002, ANIDIL RAJENDRAN wrote: > Newbie again. > Sorry if this question sounds so silly > > Want to open filenames like ~username/blah but open doesn't interpret the tilde to >mean the > home di

Re: handling microsoft word file

2002-09-04 Thread Felix Geerinckx
on Wed, 04 Sep 2002 10:53:41 GMT, [EMAIL PROTECTED] (Massimiliano Cialdi) wrote: > there exist a perl module to manage ms word file? No, not to my knowledge. Unless you are working on Win32 and have MS Word available, in which case you can use Win32::OLE. -- felix -- To unsubscribe, e-mail

Re: Cookbook example

2002-09-04 Thread Felix Geerinckx
on Wed, 04 Sep 2002 06:23:20 GMT, [EMAIL PROTECTED] (Anidil Rajendran) wrote: > expand the filename manually with substitution > > $filename =~ s{ ^ ~ ( [^/]* ) } > { $1 >? (getpwnam($1)) [7] >: ( $ENV{HOME} || $ENV

Re: Cookbook example

2002-09-04 Thread Sudarshan Raghavan
On Tue, 3 Sep 2002, ANIDIL RAJENDRAN wrote: > Newbie again. > Sorry if this question sounds so silly > > Want to open filenames like ~username/blah but open doesn't interpret the tilde to >mean the > home directory > > Solution > > expand the filename manually with substitution > > $filenam

Re: Tips, optimizing script.

2002-09-04 Thread Janek Schleicher
David Samuelsson wrote at Wed, 04 Sep 2002 09:44:01 +0200: >> Since i got so much help from here i decided to send out this script so you can >look at it. This script works for me, only on NT4+w2k though. In addition to Felix good answer, here's another hint: >> if ($viewi

handling microsoft word file

2002-09-04 Thread Massimiliano Cialdi
there exist a perl module to manage ms word file? thanks -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: avoid creating directories in a particular path

2002-09-04 Thread Dharmendra Rai
yeah, but it came after mine was posted on the list. - Get a bigger mailbox -- choose a size that fits your needs.

RE: avoid creating directories in a particular path

2002-09-04 Thread Javeed SAR
Hi, I have written a function ,got it ,thanks for ur help, Regards Javeed -Original Message- From: Sudarshan Raghavan [mailto:[EMAIL PROTECTED]] Sent: Thursday, September 05, 2002 1:30 PM To: Perl beginners Subject: Re: avoid creating directories in a particular path On Wed, 4 Sep

Cookbook example

2002-09-04 Thread ANIDIL RAJENDRAN
Newbie again. Sorry if this question sounds so silly Want to open filenames like ~username/blah but open doesn't interpret the tilde to mean the home directory Solution expand the filename manually with substitution $filename =~ s{ ^ ~ ( [^/]* ) } { $1

Re: avoid creating directories in a particular path

2002-09-04 Thread Sudarshan Raghavan
On Wed, 4 Sep 2002, Dharmendra Rai wrote: > This will not work as it will also forbid creating new files(according to the >question only sub-DIRS r not allowed) in that directory. > There is no Unix-provided solution for this. One can write a function, > which can be called first in any perl c

Re: locking a file in linux

2002-09-04 Thread Sudarshan Raghavan
On Wed, 4 Sep 2002, Ramprasad A Padmanabhan wrote: > Thanx All >But I will still like to have kernel enforced mandatory locking on > the file Can you tell me how to do it For starters your kernel must support mandatory locking, after checking that you will have to unmount the filesystem, e

Re: Tips, optimizing script.

2002-09-04 Thread Felix Geerinckx
on Wed, 04 Sep 2002 07:44:01 GMT, [EMAIL PROTECTED] (David Samuelsson) wrote: [Why are you quoting yourself in an original post?] >> I want tips, on >> optimizing, and things that can be done smaller and better. >> Changes goes inside the box. >> use strict; >> my (@vobs,$vob,$view,$text,@vie

Perl taking a long time to exit? Freeing memory?

2002-09-04 Thread Jeff AA
Hi folks, I have a Perl script that creates a large hash, from a collection of files. I am running Perl 5.6.1 on SMP Linux 2.4.18, top shows my process using up to 700MB of memory (which is fine on our servers). I have noticed though that when perl hits my exit 0; line, the process pauses for

Tips, optimizing script.

2002-09-04 Thread David Samuelsson (PAC)
> Since i got so much help from here i decided to send out this script so you can look >at it. This script works for me, only on NT4+w2k though. > > What it does is it prints an HTML page with all checkouts, for our clearcase system. >And the HTML is probably really bad written, since i just to