Re: Running a script in the system account

2006-03-20 Thread Jim Hill
Paul Sobey wrote: > Jim Hill wrote: > > > Instead of running all day with a cmd shell with system account > > privileges, I think it would be safer if only the scripts which > > need such privileges are able to obtain them at runtime > > Have you considered psexe

Re: Running a script in the system account

2006-03-20 Thread Jim Hill
mark pryor wrote: > Foo Ji-Haw <[EMAIL PROTECTED]> wrote: > > Jim Hill wrote: > > > mark pryor wrote: > > > > > > > You can use the WinXP schtasks utility to run a script > > > > in the SYSTEM account. > > > > > I can'

Re: Running a script in the system account

2006-03-20 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > mark pryor wrote: > > > Jim Hill <[EMAIL PROTECTED]> wrote: > > > > > > > [...] is there a better, safer way > > > > of gaining system account status within a perl scri

Re: Running a script in the system account

2006-03-18 Thread Jim Hill
mark pryor in <[EMAIL PROTECTED]>: > --- Jim Hill <[EMAIL PROTECTED]> wrote: > > > [...] is there a better, safer way > > of gaining system account status within a perl script? Thanks for the response, Mark. > You can use the WinXP schtasks utility to run a s

Running a script in the system account

2006-03-18 Thread Jim Hill
Hi all My mta, Mailtraq , contains a custom active-x control which can be accessed only when it is running as an application, not as a service. If Mailtraq is started as a service, its normal mode, the active-x control can't be instanced in perl or javascript ... | test.

Re: Pattern matching

2006-03-03 Thread Jim Hill
Thomas, Mark - BLS CTR in <[EMAIL PROTECTED]>: > > > > > Jim Hill wrote: > > > > > > > > > > > | $ini{section}{match} = '$1 $2'; > > > > > > ... however that just prints "$1 $2" as a literal

Re: Pattern matching

2006-03-03 Thread Jim Hill
Thomas, Mark in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > | $ini{section}{match} = '$1 $2'; > > ... however that just prints "$1 $2" as a literal string. > > Hint: the above two lines of your post answer your own question. Do they? That does

Re: Pattern matching

2006-03-03 Thread Jim Hill
Thomas, Mark - BLS CTR in <[EMAIL PROTECTED]>: > Glad you got it... I didn't realize you *wanted* the '$1 $2' to be > *stored* as a literal string. There's the rub, neither did I. -- ___ Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveS

Re: Pattern matching

2006-03-03 Thread Jim Hill
$Bill Luebkert wrote: > Jim Hill in <[EMAIL PROTECTED]>: > > > I have a log analysis script to which I'm trying to add a pattern > > matching option. [snip] > > The eval already suggested by Chris should work It doesn't, unfortunately, unless I'm m

Re: Pattern matching

2006-03-03 Thread Jim Hill
Thomas, Mark in <[EMAIL PROTECTED]>: > > From: Jim Hill [mailto:[EMAIL PROTECTED] > > Thomas, Mark in <[EMAIL PROTECTED]>: > > > Jim Hill wrote: > > > > > > > | $ini{section}{match} = '$1 $2'; > > > > ... however th

Re: Pattern matching

2006-03-03 Thread Jim Hill
Chris Wagner in <[EMAIL PROTECTED]>: > At 12:07 AM 3/2/2006 +, perl-win32-users@listserv.ActiveState.com wrote: > > | print $ini{section}{match}; > > > >... however that just prints "$1 $2" as a literal string. > > I would try print eval $ini{section}{match}. Sorry, I should have mentioned t

Pattern matching

2006-03-01 Thread Jim Hill
Hi all I have a log analysis script to which I'm trying to add a pattern matching option. The script is controlled via the contents of an inifile, for example ... [exception] title=ERROR: exceptions extract=C000 .* EXCEPTION regex=^.*? (..:..:..) .*? \((.*?)\) .* match=$1 $2 ... which the

Re: Date format patterns

2004-10-29 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > [...] the problem is that I > > can't predict the date format which other users will retrieve > > from their registries. > > If you can't predict the date format, I don't see how

Re: Date format patterns

2004-10-29 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > [my registry] returns "dd/mm/" > > but it might be "mm-dd-yy" in the USA. > > > > Is there a reliable way to convert "dd/mm/" strings into > > "%

Date format patterns

2004-10-29 Thread Jim Hill
Hi all My perl script retrieves an application-specific date format string from the registry and I need to produce a date string in that format to search for log entries on a specified date. My script may be used internationally so I need to accommodate all possible date formats. A query on my reg

Re: Checkboxes

2004-01-27 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > Flags=1414 > > > > Is there a module or a perl algorithm for determining which of > > the 14 checkboxes are enabled from a "Flags=" value? > > I would just use a hash and for l

Checkboxes

2004-01-27 Thread Jim Hill
Hi all The [subscribers] section in the .cfg file of my mailing list manager gives a flag value for each subscriber ... Flags=1414 ... which is linked to a set of gui checkboxes - some, but not all, of which are mutually exclusive. Checking each option in turn and monitoring the .cfg file result

Re: Finding the end of message headers

2004-01-04 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > my @array = ""; > > The proper way would be either of these: > > my @array; > my @array = (); Thanks, useful to know that. Further tests show that I can now chain together more neatly

Re: random keyword generator

2004-01-03 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Murali M wrote: > > >i need random keyword generator. > > my @array = qw(a b c d e f g h i j k l m n); > print $array[int rand @array], "\n"; Brilliant. That's just the input I needed to generate my random eight character hex string. Thanks, $Bill.

Re: Finding the end of message headers

2004-01-03 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > Jim Hill wrote: > > > [snip] but I'm clearly doing something structurally wrong. > > I thought that /^$/ matched only to a blank line. Right? > > No never checked the header for a references header. [...] No, that was

Re: Net::DNS::Resolver - IP address to DNS name?

2003-12-22 Thread Jim Hill
Rush, Thomas in <[EMAIL PROTECTED]>: > I have been trying to convert an IP address into it's DNS name using > DNS::Resolver without much joy. Your code, with the exception of "use Net::DNS;" missing at the start, works for me, v5.6.1.635 on win2k. > The return value fails with the following erro

Re: Send email in ActivePerl using SMTP

2002-06-12 Thread Jim Hill
$Bill Luebkert in <[EMAIL PROTECTED]>: > [EMAIL PROTECTED] wrote: > > > I tried the following to use SMTP to send email: > > > >use Net::SMTP; > >$optServer = 'luxn.com'; > >$optTo = "[EMAIL PROTECTED]"; > > > > Can't call method "mail" on an undefined value at > > mailtest.pl line