Re: Question on SAP-RFC program

2005-02-08 Thread Sisyphus
James wrote:
my $it = $rfc->discover("RFC_READ_TABLE");
I don't know anything about this module - but I can see in the docs 
where you got the code from.

However, if you go to the actual 'discover()' documentation, you see the 
example is written as:

$iface = $rfc->discover('RFC_READ_REPORT');
Perhaps *that* is the incantation you should be using ?
(Sorry if that's a stupid suggestion :-)
Cheers,
Rob
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Image::Magick missing Resize.al

2005-02-08 Thread Sisyphus
Sisyphus wrote:
My guess is that 
there's no Resize method with the ImageMagick version that you have. 
Best to update to a later version of ImageMagick (and Perl, too :-)

Hmmm  on looking closer it seems to me that 'Resize' has always been 
part of ImageMagick. That post from the archive (that you gave a link 
to) was suggesting that the problem had something to do with your 
ImageMagick setup (as distinct from perl's Image::Magick) - but I 
couldn't really understand it either.

(It's probably still a good idea to update if possible :-)
Cheers,
Rob
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Intercept IE or Netscape

2005-02-08 Thread $Bill Luebkert
Jerry Kassebaum wrote:

> This may be a socket question.
> 
> Is there a way to read the data coming into my computer to a file on its way 
> to my browser?  Is there a way to intercept what the browser is going to 
> send to the internet, change it, and then send it out? Man, that would make 
> scraping the internet a piece of cake!

Thsi may be useful :

http://schmerg.pwp.blueyonder.co.uk/HttpSniffer.pl.txt

-- 
  ,-/-  __  _  _ $Bill LuebkertMailto:[EMAIL PROTECTED]
 (_/   /  )// //   DBE CollectiblesMailto:[EMAIL PROTECTED]
  / ) /--<  o // //  Castle of Medieval Myth & Magic http://www.todbe.com/
-/-' /___/_<_http://dbecoll.tripod.com/ (My Perl/Lakers stuff)
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Image::Magick Crop

2005-02-08 Thread Sisyphus
Chris wrote:
Is it just me or does the crop function not work at all?

$x = $image->Crop(geometry=>'100x100"+100"+100');
warn "$x" if "$x";
No problems for me with that. (Image::Magick 5.26 and ImageMagick 5.5.5-3)
Cheers,
Rob
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Question on SAP-RFC program

2005-02-08 Thread James
Can anybody tell me what's wrong in this program? 
When I execute it I get this error:
"Can't call method "QUERY_TABLE" on an undefined value
at reports.pl line 20"
Thanks

use lib 'blib/lib';
use lib 'blib/arch';
use SAP::Rfc;
use Data::Dumper;

my $rfc = new SAP::Rfc(
  ASHOST   => 'mysap',
  USER => 'test',
  PASSWD   => '',
  LANG => 'EN',
  CLIENT   => '255',
  SYSNR=> '00',
  TRACE=> '1' );
if ( $rfc->is_connected() )
 {print "CONNECTED\n"; }
else
 { print "CONNECTION REFUSED\n"; }

my $it = $rfc->discover("RFC_READ_TABLE");
$it->QUERY_TABLE('TRDIR');
print "HELLO\n";
$it->DELIMITER('|');
$it->ROWCOUNT( 10 );
$it->OPTIONS( ["NAME LIKE 'RS%'"] );
$rfc->callrfc( $it );


--- James <[EMAIL PROTECTED]> wrote:

> Hi ,
> I am using SAP::RFC module to connect to a SAP
> database and extracting tsome data.
> So far I was able to connect sucessfully.
> The problem is how do I get exract info by a
> specific
> value?
> Is there a way to  get the tables name in my SAP
> database?
> 
> Hope to get some help.
> Thanks
> James
> 
> 
>   
> __ 
> Do you Yahoo!? 
> Meet the all-new My Yahoo! - Try it today! 
> http://my.yahoo.com 
>  
> 
> ___
> Perl-Win32-Users mailing list
> Perl-Win32-Users@listserv.ActiveState.com
> To unsubscribe:
> http://listserv.ActiveState.com/mailman/mysubs
> 




__ 
Do you Yahoo!? 
Meet the all-new My Yahoo! - Try it today! 
http://my.yahoo.com 
 

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Image::Magick Crop

2005-02-08 Thread Chris
Is it just me or does the crop function not work at all?

use Image::Magick;

my($image, $x);

$image = Image::Magick->new;
$x = $image->Read('input.jpg');
warn "$x" if "$x";

$x = $image->Crop(geometry=>'100x100"+100"+100');
warn "$x" if "$x";

$x = $image->Write('output.jpg');
warn "$x" if "$x";


The above will always print the error "Exception 410: invalid geometry
`100x100"+100"+100'" reguardless of the image type or size.

- Chris

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Image::Magick missing Resize.al

2005-02-08 Thread Sisyphus
Kamphuys, ing. K.G. (Koen) wrote:
Hi all,
I found this thread in the archives:
http://www.mail-archive.com/perl-win32-users@listserv1.activestate.com/msg00
371.html
unfortunately it didn't clue to a solution.
Running perl 5.008 and module version 4.29 (apparent to the $VERSION value
in the module) I get the same error (Can't locate
auto/Image/Magick/Resize.al in @INC (@INC contains: C:/Perl/lib
C:/Perl/site/lib .) at test2.pl line 4) and indeed the file is not present
on the given location neither mentioned in the packlist.  Can't find it in
any distribution of PerlMagick or Imagemagick either.
I don't think the file exists anywhere at all. When perl realises that 
it doesn't know what 'Resize' is, it goes looking to see if it's in the 
Resize.al file. When it can't find that file, it decides to complain 
about that, rather than complain about the real problem - which is 
simply that it doesn't understand 'Resize'.

This works... so it looks like everything is installed OK:
use warnings; # always
use Image::Magick;
$image = Image::Magick->new;
$image->Set(size=>'100x100');
$image->ReadImage('xc:white');
$image->Set('pixel[49,49]'=>'red');
$filename = 'e:\tmp\test.gif';
$image->Write(filename=>$filename);
This doesn't:
use warnings; # always
use Image::Magick;
$image = Image::Magick->new;
$image -> Read (filename=>'e:\tmp\stats\stats.jpg');
$image -> Resize (width=>138, height=>92);
$image -> Write (filename=>'e:\tmp\stats\stats2.jpg');
Any help would be greatly appreciated.
Well  it's documented at http://www.imagemagick.org/www/perl.html - 
and it certainly exists and works on my version (5.26). My guess is that 
there's no Resize method with the ImageMagick version that you have. 
Best to update to a later version of ImageMagick (and Perl, too :-)

The following ran fine for me:
use warnings;
use Image::Magick;
$im = Image::Magick->new(size=>'384x256');
$im -> Resize (width=>148, height=>92);
print "DONE\n";
Cheers,
Rob
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Regular Expression Help Please

2005-02-08 Thread Chris


-Original Message-

One of the columns I'm calling out of my database is the email one. I'ts in 
MAPI format, so I need to extract the very last part. So the bottom example 
I would need to grab

JDoe

MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe


Then I can append the rest as

[EMAIL PROTECTED]

Every one is the same format,

MAPI:{Smith, Jane}EX:/o=Company/ou=Site/cn=Recipients/cn=LJSmith

Any help greatly appreciated.
Thanks in advance
Steve

---

I know there's probably a better way to do this, but...

my $field='MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe';
my @bla = split(/=/, $field);
print pop(@bla);


- Chris




___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Regular Expression Help Please

2005-02-08 Thread Chris Wagner
You can get that plus some other info with this regex:

$string = 'MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe';
($lastname, $firstname, $mailid) = $string =~ m/^.+?\{(\w+),
(\w+)\}.+?cn\=(\w+)$/;


At 09:46 PM 2/8/05 +, steve silvers wrote:
>One of the columns I'm calling out of my database is the email one. I'ts in 
>MAPI format, so I need to extract the very last part. So the bottom example 
>I would need to grab
>
>JDoe
>




___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Intercept IE or Netscape

2005-02-08 Thread Jonathan Epstein
At 04:11 PM 2/8/2005, Glenn Linderman wrote:
>On approximately 2/8/2005 11:32 AM, came the following characters from the 
>keyboard of Jerry Kassebaum:
>
>>This may be a socket question.
>>Is there a way to read the data coming into my computer to a file on its way 
>>to my browser?  Is there a way to intercept what the browser is going to send 
>>to the internet, change it, and then send it out? Man, that would make 
>>scraping the internet a piece of cake!
>>Jerry Kassebaum
>
>There is a Web scraping proxy that was published in the June 2003 DDJ.
>
>See ddj.com for details.  The proxy code and documentation are available  from 
>their archives.
>
>-- 
>Glenn -- http://nevcal.com/

Cool.  Your info led me here:
  http://www.research.att.com/~hpk/wsp/

Jonathan 

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Regular Expression Help Please

2005-02-08 Thread Charles K. Clarkson
From: [EMAIL PROTECTED] <> wrote:

: One of the columns I'm calling out of my database is the email
: one. I'ts in MAPI format, so I need to extract the very last
: part. So the bottom example I would need to grab
: 
: JDoe
: 
: MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe
: 
: 
: Then I can append the rest as
: 
: [EMAIL PROTECTED]
: 
: Every one is the same format,
: 
: MAPI:{Smith, Jane}EX:/o=Company/ou=Site/cn=Recipients/cn=LJSmith
: 
: Any help greatly appreciated.


my $field = 'MAPI:{Smith,
Jane}EX:/o=Company/ou=Site/cn=Recipients/cn=LJSmith';
my $email;
if ( $field =~ /=([^=]+)$/ ) {
$email = "[EMAIL PROTECTED]";

} else {
# Uh Oh!
}


The '$' is a zero length placeholder for the end of
the string. [^=] is a character class of all characters
which are not the equal sign. Anything inside parenthesis
'()' will be captured to $1.

HTH,

Charles K. Clarkson
-- 
Mobile Homes Specialist
254 968-8328

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Regular Expression Help Please

2005-02-08 Thread Gerber, Christopher J
-Original Message-
> One of the columns I'm calling out of my database is the email one. I'ts
in MAPI format,
> so I need to extract the very last part. So the bottom example I would
need to grab
> 
> JDoe
> 
> MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe

Steve,

An easy way might be:

$_ = 'MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe';
/([^=]+)$/;
print $1;

Chris


LEGAL NOTICE
Unless expressly stated otherwise, this message is confidential and may be 
privileged. It is intended for the addressee(s) only. Access to this E-mail by 
anyone else is unauthorized. If you are not an addressee, any disclosure or 
copying of the contents of this E-mail or any action taken (or not taken) in 
reliance on it is unauthorized and may be unlawful. If you are not an 
addressee, please inform the sender immediately.

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Regular Expression Help Please

2005-02-08 Thread steve silvers
One of the columns I'm calling out of my database is the email one. I'ts in 
MAPI format, so I need to extract the very last part. So the bottom example 
I would need to grab

JDoe
MAPI:{Doe, John}EX:/o=Company/ou=Site/cn=Recipients/cn=JDoe
Then I can append the rest as
[EMAIL PROTECTED]
Every one is the same format,
MAPI:{Smith, Jane}EX:/o=Company/ou=Site/cn=Recipients/cn=LJSmith
Any help greatly appreciated.
Thanks in advance
Steve
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Re: Intercept IE or Netscape

2005-02-08 Thread Lyle Kopnicky
Jerry Kassebaum wrote:
This may be a socket question.
Is there a way to read the data coming into my computer to a file on 
its way to my browser?  Is there a way to intercept what the browser 
is going to send to the internet, change it, and then send it out? 
Man, that would make scraping the internet a piece of cake!

Jerry Kassebaum
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
You need to create a proxy server.  Write a program that will process 
the requests that come from your browser, then pass them off to the 
remote sites.  And respond to what's coming back, process it then return 
it to your browser.  Just set up the proxy to sit on some local port, 
and configure your browser to use it as a proxy.

There are existing proxies that may be configured to do what you want - 
maybe you won't have to write one.

- Lyle
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Intercept IE or Netscape

2005-02-08 Thread Ken Cornetet
It would probably be easier to drive IE via OLE

my $ie = Win32::OLE->new('InternetExplorer.Application');

$ie->Navigate("http://whatever";);

$ie->{Toolbar} = 0;
$ie->{StatusBar} = 0;
$ie->{Width} = 800;
$ie->{Height} = 400;
$ie->{Left} = 0;
$ie->{Top} = 0;

while( $ie->{Busy} ) {
Win32::Sleep(200);
}

$ie->{Visible} = 1;
Win32::Sleep(200);

print $ie->Document->Body->{InnerHTML};
$ie->Quit;

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Jerry Kassebaum
Sent: Tuesday, February 08, 2005 2:33 PM
To: perl-win32-users@listserv.ActiveState.com
Subject: Intercept IE or Netscape


This may be a socket question.

Is there a way to read the data coming into my computer to a file on its
way 
to my browser?  Is there a way to intercept what the browser is going to

send to the internet, change it, and then send it out? Man, that would
make 
scraping the internet a piece of cake!

Jerry Kassebaum


___
Perl-Win32-Users mailing list Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Intercept IE or Netscape

2005-02-08 Thread Jerry Kassebaum
This may be a socket question.
Is there a way to read the data coming into my computer to a file on its way 
to my browser?  Is there a way to intercept what the browser is going to 
send to the internet, change it, and then send it out? Man, that would make 
scraping the internet a piece of cake!

Jerry Kassebaum
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Image::Magick missing Resize.al

2005-02-08 Thread Kamphuys, ing. K.G. (Koen)
Hi all,

I found this thread in the archives:

http://www.mail-archive.com/perl-win32-users@listserv1.activestate.com/msg00
371.html

unfortunately it didn't clue to a solution.

Running perl 5.008 and module version 4.29 (apparent to the $VERSION value
in the module) I get the same error (Can't locate
auto/Image/Magick/Resize.al in @INC (@INC contains: C:/Perl/lib
C:/Perl/site/lib .) at test2.pl line 4) and indeed the file is not present
on the given location neither mentioned in the packlist.  Can't find it in
any distribution of PerlMagick or Imagemagick either.

This works... so it looks like everything is installed OK:

use Image::Magick;
$image = Image::Magick->new;
$image->Set(size=>'100x100');
$image->ReadImage('xc:white');
$image->Set('pixel[49,49]'=>'red');
$filename = 'e:\tmp\test.gif';
$image->Write(filename=>$filename);

This doesn't:

use Image::Magick;
$image = Image::Magick->new;
$image -> Read (filename=>'e:\tmp\stats\stats.jpg');
$image -> Resize (width=>138, height=>92);
$image -> Write (filename=>'e:\tmp\stats\stats2.jpg');

Any help would be greatly appreciated.

-- 
Koen Kamphuys
Web master, Dutch ministry of Agriculture, Nature and Food Quality.
___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


RE: Create User Accounts Using Perl

2005-02-08 Thread Anderson, Mark (Service Delivery)
Yes but how you do it depends on various factors... 

If it's AD you should check out the EZADScriptomatic tool from "The
Scripting guys" at technet (www.microsoft.com/technet)

If you really want to use Perl you can either use the ADSI objects and
Win32::OLE or you can go with Win32::AdminMisc from www.Roth.net

If you were in control of the CSV and there's noting weird in any of the
fields you might be quicker/easier to try the VBScript route first (sine MS
have already documented that for you).

Kind regards,

Mark Anderson
Service Improvement Project
Level 2, 113 Dundas Street
Edinburgh, EH3 5DE
Tel: 0131 523 8786
Mob: 07808 826 063


> -Original Message-
> From: [EMAIL PROTECTED]
> [SMTP:[EMAIL PROTECTED] On Behalf Of
> Jonathan Dudson
> Sent: Tuesday, February 08, 2005 12:01 PM
> To:   perl-win32-users@listserv.ActiveState.com
> Subject:  Create User Accounts Using Perl 
> 
> *** WARNING : This message originates from the Internet ***
> 
> 
> 
> I have various accounts under which I wish to import to a system I have a
> csv with accounts and passwords.
> 
>  
> 
> Can I use perl to create the accounts as there a over 300 accounts, if so
> how can I go about doing it.
> 
>  
> 
> Jay Dudson
> 
> Operations And Support, Idesta Solutions Ltd
> 
>  
> 
> *: 0870 830 5202 (Support)
> 
> *: 0870 830 5257 (Fax)
> 
> *: 0870 830 5256 (Sales)
> 
> *: [EMAIL PROTECTED] 
> 
> *: 
> 
>  
> 
> Office:
> 
> 197 North Street 
> 
> Leeds
> 
> LS7 2AA
> 
>  
>  << File: ATT2208361.txt >> 


The Royal Bank of Scotland plc, Registered in Scotland No. 90312. Registered 
Office: 36 St Andrew Square, Edinburgh EH2 2YB

The Royal Bank of Scotland plc is authorised and regulated by the Financial 
Services Authority and represents The Royal Bank of Scotland Marketing Group. 
The Bank sells life policies, collective investment schemes and pension 
products and advises only on the Marketing Group's range of these products and 
on a With-Profit Bond produced by Norwich Union Life (RBS) Limited.

This e-mail message is confidential and for use by the addressee only. If the 
message is received by anyone other than the addressee, please return the 
message to the sender by replying to it and then delete the message from your 
computer. Internet e-mails are not necessarily secure. The Royal Bank of 
Scotland plc does not accept responsibility for changes made to this message 
after it was sent.

Whilst all reasonable care has been taken to avoid the transmission of viruses, 
it is the responsibility of the recipient to ensure that the onward 
transmission, opening or use of this message and any attachments will not 
adversely affect its systems or data. No responsibility is accepted by The 
Royal Bank of Scotland plc in this regard and the recipient should carry out 
such virus and other checks as it considers appropriate.

___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs


Create User Accounts Using Perl

2005-02-08 Thread Jonathan Dudson








I have various accounts under which I wish to import to a
system I have a csv with accounts and passwords.

 

Can I use perl to create the accounts as there a over 300
accounts, if so how can I go about doing it.

 

Jay Dudson

Operations And Support, Idesta Solutions
Ltd

 

(: 0870 830 5202 (Support)

+: 0870 830 5257
(Fax)

(: 0870 830 5256 (Sales)

*: [EMAIL PROTECTED]

ü: http://www.idesta.com

 

Office:

197 North Street 

Leeds

LS7 2AA

 






___
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs