Re: getting process id under NT

2008-08-02 Thread epanda
I have tried your pm and it works well on XP but does not on my NT
platform.

I have the following error : Error - Variant '$_[0]' support status is
unknown. This can happen if
you 'use Win32::Process::Info ();'. Please do not do that.
eod


When I set the environment variables I have Windows_NT has OS.
So it should work no ?

Happytown a écrit :
> On Jul 30, 11:09�am, [EMAIL PROTECTED] (Ron Bergin) wrote:
> > On Jul 29, 9:12�am, [EMAIL PROTECTED] (Epanda) wrote:
> >
> >
> >
> >
> >
> > > Hi HappyTown
> >
> > > I have seen your web link but I don't think it can show me the PID if
> > > I give the name of an existing and running Win NT application.
> >
> > > On 28 juil, 05:24, [EMAIL PROTECTED] (Happytown) wrote:
> >
> > > > On Jul 26, 3:14�am, [EMAIL PROTECTED] (Epanda) wrote:
> >
> > > > > Hi,
> >
> > > > > I would like to know if it is possible to get win32 process ID under
> > > > > Windows NT without using Win32::OLE because this one does not work
> > > > > under NT.
> >
> > > > > Thanks
> >
> > > > Maybe, this module can help 
> > > > you:http://search.cpan.org/~cosimo/Win32-API-0.55/API.pm
> >
> > Win32::API will do what you need, however, it's not the easiest to
> > use. �Getting the process info requires calling several (about 5)
> > different C functions in kernel32.dll and setting up the function
> > calls can be tricky.
> >
> > It would be easier and better to use Win32::Process::Info (which uses
> > Win32::API) and let it deal with setting up the function 
> > calls.http://search.cpan.org/~wyant/Win32-Process-Info-1.012/lib/Win32/Proc...-
> >  Hide quoted text -
> >
> > - Show quoted text -
>
> Yes, you're right.


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: getting process id under NT

2008-07-29 Thread epanda
Hi HappyTown

I have seen your web link but I don't think it can show me the PID if
I give the name of an existing and running Win NT application.


On 28 juil, 05:24, [EMAIL PROTECTED] (Happytown) wrote:
> On Jul 26, 3:14 am, [EMAIL PROTECTED] (Epanda) wrote:
>
> > Hi,
>
> > I would like to know if it is possible to get win32 process ID under
> > Windows NT without using Win32::OLE because this one does not work
> > under NT.
>
> > Thanks
>
> Maybe, this module can help 
> you:http://search.cpan.org/~cosimo/Win32-API-0.55/API.pm


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




getting process id under NT

2008-07-26 Thread epanda
Hi,

I would like to know if it is possible to get win32 process ID under
Windows NT without using Win32::OLE because this one does not work
under NT.

Thanks


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: perl2exe

2008-07-24 Thread epanda
What is the version I need for perl2exe which is compatible with
5.10 ?

I don't understand why perl2exe of 2001 is not compatible because only
modules change in perl 5.0 to 5.10.
So I don't understand and I know that lastest version of perl2exe is
not free and I can't buy it.

Is there another solution ?

Thanks



On 24 juil, 10:55, [EMAIL PROTECTED] (Stewart Anderson)
wrote:
> > -Original Message-
> > From: Rob Dixon [mailto:[EMAIL PROTECTED]
> > Sent: 23 July 2008 21:10
> > To: [EMAIL PROTECTED]
> > Cc: epanda
> > Subject: Re: perl2exe
>
> > epanda wrote:
>
> > > I am using perl2exe (Oct 27, 2001) and it works fine for little
> script
> > > without several .pm and it does good binary conversion.
> > > I am working without any install of perl8.8 or 10.
>
> > > Now I want to include Win32::process which includes others
> > > dependencies and I would like to know if I can continue using
> perl2exe
> > > and install perl 10.
>
> > > How can I include all .pm easily with the install of perl 10 and
> > > perl2exe is it compatible ?
>
> > You need to install a different version of perl2exe to build images
> that
> > use
> > Perl 5.10. You should install Perl 5.10 on your PC as well as the
> relevant
> > modules for your program. Once you have tested it thoroughly under the
> > perl
> > interpreter you can use perl2exe to build an executable image.
>
> > HTH,
>
> > Rob
>
> [Stewart Anderson]
> Hi,  I thought I read  somewhere that generating executable Perl
> binaries was  at best in the  prototype  stages of evolution.  I'm not
> putting down the  efforts of  IndigoSTAR  or any others who are involved
> in  producing tools like this,  just seeking  a clarification on how
> robust and reliable the programs created are as compared to their
> original Perl counterparts?
>
> Thanks
>
> Stu.
>
> Information in this email including any attachments may be privileged, 
> confidential and is intended exclusively for the addressee. The views 
> expressed may not be official policy, but the personal views of the 
> originator. If you have received it in error, please notify the sender by 
> return e-mail and delete it from your system. You should not reproduce, 
> distribute, store, retransmit, use or disclose its contents to anyone. Please 
> note we reserve the right to monitor all e-mail communication through our 
> internal and external networks. SKY and the SKY marks are trade marks of 
> British Sky Broadcasting Group plc and are used under licence. British Sky 
> Broadcasting Limited (Registration No. 2906991), Sky Interactive Limited 
> (Registration No. 3554332), Sky-In-Home Service Limited (Registration No. 
> 2067075) and Sky Subscribers Services Limited (Registration No. 2340150) are 
> direct or indirect subsidiaries of British Sky Broadcasting Group plc 
> (Registration No. 2247735). All of the companies mentioned in this paragraph 
> are incorporated in England and Wales and share the same registered office at 
> Grant Way, Isleworth, Middlesex TW7 5QD.


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




perl2exe

2008-07-23 Thread epanda
Hello

I am using perl2exe (Oct 27, 2001) and it works fine for little script
without several .pm and it does good binary conversion.
I am working without any install of perl8.8 or 10.

Now I want to include Win32::process which includes others
dependencies and I would like to know if I can continue using perl2exe
and install perl 10.

How can I include all .pm easily with the install of perl 10 and
perl2exe is it compatible ?

Thanks
Best Regards
Epanda


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: Parsing XML

2008-07-19 Thread epanda
Hi Rob,

I only have to read values from nodes but I am amazing by what you
say. But the XML file can take 10 Mb.
I thought that expat was the faster parser  because I have found this
link http://www.xml.com/lpt/a/37. Maybe it was true in 1999 but it
isn't not at all.

You have to notice that the parser has to be a modular one that I can
call in C++ method.

Could RegExp be more efficient and faster than a classical Parser XPat
or MSXML ?

More than that, I have heard that there is another generation which
combine DOM and SAX parser, it is a microsoft I think but I have lost
the name.

Thanks



On 19 juil, 03:14, [EMAIL PROTECTED] (Rob Dixon) wrote:
> Epanda wrote:
>
> > Epanda wrote:
>
> >> I would like to know if we can parse XML with regexp faster than with
> >> an MSXML or Xerces library ?
>
> > I just want to parse an XML and I have seen that the XML!!Parser of
> > Perl based on Expat is the most faster  ofth world, I don't know Twig.
>
> > My XML is classical :
> > 
> > 
>
> > 
> >    
> >            
> >                    OM
> >                    SAT
> >            
> >            
> >                    TPS
> >                    3E+01
> >            
> >    
> > 
>
> > but can be very big.
>
> XML::Twig is built on Expat, and is especially good at processing large files
> one element at a time instead of loading the whole file into memory first. For
> instance, if your data consists of multiple independent  elements
> XML::Twig can be set up to process them individually and so save memory. Take 
> a
> look herehttp://www.xmltwig.com/xmltwig/
>
> But if you are hoping to write something that is faster than MSXML or Xerces 
> you
> may be unsucessful. Perl also has XML::LibXML and XML::Xerces modules as well 
> if
> you want to try those.
>
> What do you need to do with the data? It may be possible with regular
> expressions if the data is consistently formatted.
>
> Rob


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: Parsing XML

2008-07-19 Thread epanda
I would implement XML::LibXML or a better one, twig or Expat just to
see if it is faster and then implement it in a C++ class.

Have you got a sample of using Expat ? or Twig ?

Are those lib available in C++ and twig or expat are faster than MSXML
or Xerces ?

Thanks


On 19 juil, 13:15, [EMAIL PROTECTED] (Dermot) wrote:
> 2008/7/19 Amit Saxena <[EMAIL PROTECTED]>:
>
>
>
> > On Sat, Jul 19, 2008 at 6:44 AM, Rob Dixon <[EMAIL PROTECTED]> wrote:
>
> >> Epanda wrote:
>
> >> > Epanda wrote:
>
> >> >> I would like to know if we can parse XML with regexp faster than with
> >> >> an MSXML or Xerces library ?
>
> >> > I just want to parse an XML and I have seen that the XML!!Parser of
> >> > Perl based on Expat is the most faster  ofth world, I don't know Twig.
>
> >> > My XML is classical :
> >> > 
> >> > 
>
> >> > 
> >> >       
> >> >               
> >> >                       OM
> >> >                       SAT
> >> >               
> >> >               
> >> >                       TPS
> >> >                       3E+01
> >> >               
> >> >       
> >> > 
>
> >> > but can be very big.
>
> >> XML::Twig is built on Expat, and is especially good at processing large
> >> files
> >> one element at a time instead of loading the whole file into memory first.
> >> For
> >> instance, if your data consists of multiple independent  elements
> >> XML::Twig can be set up to process them individually and so save memory.
> >> Take a
> >> look herehttp://www.xmltwig.com/xmltwig/
>
> >> But if you are hoping to write something that is faster than MSXML or
> >> Xerces you
> >> may be unsucessful. Perl also has XML::LibXML and XML::Xerces modules as
> >> well if
> >> you want to try those.
>
> >> What do you need to do with the data? It may be possible with regular
> >> expressions if the data is consistently formatted.
>
> >> Rob
> >> Hi !
>
> > I am using use XML::SAX::ParserFactory .
>
> > I want to know whether it's a better alternative than suggested so far in
> > this thread or not ?
>
> > If not, please suggest.
>
> > Regards,
> > Amit Saxena
>
> In many ways it's a preference which parser you use. I would say if
> you have a large amount of data in your XML then, XML::LibXML is a the
> best option. I haven't seen anything like it for sheer speed.
>
> Dp.


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: Parsing XML

2008-07-18 Thread epanda
On 18 juil, 21:08, [EMAIL PROTECTED] (Epanda) wrote:
> Hi,
>
> I would like to know if we can parse XML with regexp faster than with
> an MSXML or Xerces library ?
>
> Thanks
> Best Regards

I just want to parse an XML and I have seen that the XML!!Parser of
Perl based on Expat is the most faster  ofth world, I don't know Twig.

My XML is classical :






OM
SAT


TPS
3E+01




but can be very big.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Parsing XML

2008-07-18 Thread epanda
Hi,

I would like to know if we can parse XML with regexp faster than with
an MSXML or Xerces library ?

Thanks
Best Regards


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: regexp behin assertions ?

2008-07-03 Thread epanda
Sorry I hadn't enought time
/(? Hi
>
> Where is a solution(s) of this thread?
>
> It's a litle bit weird ask for help, and don't offer a "posible solution".
>
> At least with a study case would be enough, don't mentioning further details.
>
> cheers


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: substitution

2008-07-03 Thread epanda
It is ok I have found the good one substitution for me but I am
amazing that perl is not as clever as vimscript regex in limitation of
assertions.

ex : perl is lost when I want to say that a digit has to not be
preceed by this sentence :

/(? epanda schreef:
>
> > I want to replace my pattern by the corresponding value of the key
> > in the hash table [...]
> > with a single %s/pattern/hashpattern/g  expression
>
> Why that last condition? Sounds like homework.
> And is unsound: often you want to do the longest possible change first.
>
> --
> Affijn, Ruud
>
> "Gewoon is een tijger."


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: regexp behin assertions ?

2008-07-02 Thread epanda
I can't it is confidential and I have found.

Thanks a lot


On 2 juil, 00:46, [EMAIL PROTECTED] (Gunnar Hjalmarsson) wrote:
> epanda wrote:
> > Gunnar Hjalmarsson wrote:
> >> [ Please do not top-post! ]
>
> 
>
> >> Maybe I'm dumb, but it's not clear to me what you want to achieve. It
> >> might be easier to help you if you showed us a few _examples_, both of
> >> strings that should match and strings that should not match.
>
> > I can show you sample on hotmail if you want. files can't be shown
>
> What would Hotmail have to do with it? Can't you post sample strings here?
>
> Never mind; since you keep top-posting, I'm not inclined to help.
>
> --
> Gunnar Hjalmarsson
> Email:http://www.gunnar.cc/cgi-bin/contact.pl


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: regexp behin assertions ?

2008-07-01 Thread epanda
I can show you sample on hotmail if you want. files can't be shown

On 1 juil, 21:27, [EMAIL PROTECTED] (Gunnar Hjalmarsson) wrote:
> [ Please do not top-post! ]
>
>
>
> epanda wrote:
> > Gunnar Hjalmarsson wrote:
> >> epanda wrote:
> >>> I would like to identify in a pattern a number wich is not
>
> >>>         preceded by     another number    a word or a ';'
> >>>         followed
> >>> by       ;number
> >>> ~      ;\d+
>
> >>> I have tried this  s/\d+(?
> >> You probably want to reverse the order.
>
> >>     /(?
> > In fact I would like my number is not preceded by a    or a
> > 
>
> > I have tried that but error :
> > s/(? > lookbehind not implemented at HashTableItems.pl line 207
>
> Yes, as is stated in "perldoc perlre", "(? fixed-width look-behind. Hence you may not use the "+" quantifier.
>
> You know that the \wcharacter class includes digits, right?
>
> Maybe I'm dumb, but it's not clear to me what you want to achieve. It
> might be easier to help you if you showed us a few _examples_, both of
> strings that should match and strings that should not match.
>
> --
> Gunnar Hjalmarsson
> Email:http://www.gunnar.cc/cgi-bin/contact.pl


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: substitution

2008-07-01 Thread epanda
yes to distinguish in file3 the first d;, it is sufficient to avoid it
by preceded WORD;\s+\d+;

but I have tried that and it is not working
(? epanda wrote:
> > this is not working
>
> > here is an example of my file and I just want to replace with one
> > regexp
>
> > in file1 ddd ddd  by the value stored in my hash table
> > in file2 all d
> > in file3 not the first d; but all the others      which is preceed by
> > WORD;
>
> > in all files
> > not replacing block like that d;d;dd
> > not replacing the 2 in WORD/WORD2;
>
> > file1
> > WORD/WORD2;                         d;d;dd;    d;d;dd;  d;d;d;
> > d;d;d;   ddd  ddd  ddd  ddd  
> > WORD/WORDWORD1/WORD1;  d;d;dd;    d;d;dd;  d;d;d;  d;d;d;   ddd  ddd
> > ddd  ddd  d
>
> > file2
> > WORD;  d;  dd;  dd;  dd;  d;  d;  d;  dd;  dd;  d;  ddd;  ddd;  ddd;
> > ddd;  ddd;  ;
>
> > file3
> > WORD/WORD1;  d;   d;  ddd;  ;
>
> > Thanks Rob if you can help
>
> I think you should post some real data so that we can see the difference 
> between
> the fields you want translating. It's not clear, for instance, whether WORD is
> always the same word or if it can be used to determine the behaviour of the
> replacement.
>
> This seems to be close to what you need:
>
>     s/ (?
> but I can't see how to distinguish the first d; in file3 to be left 
> unmodified.
>
> Rob


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: regexp behin assertions ?

2008-07-01 Thread epanda
In fact I would like my number is not preceded by aor a


I have tried that but error :
s/(? epanda wrote:
> > I would like to identify in a pattern a number wich is not
>
> >         preceded by     another number    a word or a ';'
> >         followed
> > by       ;number
> > ~      ;\d+
>
> > I have tried this  s/\d+(?
> You probably want to reverse the order.
>
>      /(?
> --
> Gunnar Hjalmarsson
> Email:http://www.gunnar.cc/cgi-bin/contact.pl


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




regexp behin assertions ?

2008-06-30 Thread epanda
Hi,

I would like to identify in a pattern a number wich is not

preceded by another numbera word or a ';'
followed
by   ;number
~  ;\d+


I have tried this  s/\d+(?http://learn.perl.org/




substitution

2008-06-30 Thread epanda
Hi,


I have to do a substitution of a pattern in a text file,

this pattern is a key of a hash table previously set.


so I want to replace my pattern by the corresponding value of the key
in the hash table


ex :

file :   n1 n22

hash :   n1 => wordA
n2 => wordB
n22 => wordN

I want to have filenew like this :

file :  wordA wordN




with a single %s/pattern/hashpattern/g  expression

Thanks for helping


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/