<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
Ken,<div><br></div><div>Thank you for your quick reply.</div><div>The perl script runs as expected (please see the below output):</div><div><br></div><div><div>elijah:~ admin$&nbsp;/appl/fp/test</div><div>ver1</div><div>This is version 1</div><div>ver2</div><div>This is version 2</div><div>quit</div><div>elijah:~ admin$&nbsp;</div><div><br></div><div>However, whenever I execute it from the input processing, it looks like it is hanging and I cannot go to the next field (to stop it I have to ctrl-c it).</div><div><br></div><div>Thank you,</div><div>Flavius.</div><div><br></div><div>P.S. the presented perl script is only for testing purposes so that I can test the communication between the two.&nbsp;</div><br>&gt; Date: Sat, 11 Jul 2009 23:23:25 -0400<br>&gt; From: kenbrody@spamcop.net<br>&gt; To: flaviusm@hotmail.com<br>&gt; CC: filepro-list@lists.celestial.com<br>&gt; Subject: Re: USER command - help<br>&gt; <br>&gt; flavius m wrote:<br>&gt; &gt; <br>&gt; &gt; Hello,<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; I would like to use the "USER" command to communicate from a Filepro processing to an external perl script. I couldn't make it work and I would appreciate if somebody can help me out with a program sample or the modification of the below example I tried.<br>&gt; <br>&gt; ObAnswer:  Define "didn't work".<br>&gt; <br>&gt; What happened when you tried it?<br>&gt; <br>&gt; If you run the Perl script from the command prompt, and type "ver1" and <br>&gt; "ver2", does it respond as you expect?<br>&gt; <br>&gt; <br>&gt; &gt; Input processing<br>&gt; &gt; ------------------------<br>&gt; &gt;  1  -------   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -<br>&gt; &gt; @wlf1  ? If:                                                                   ?<br>&gt; &gt;        Then: USER tst=/appl/fp/test                                            ?<br>&gt; &gt;   2  -------   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -<br>&gt; &gt;        ? If:                                                                   ?<br>&gt; &gt;        Then: tst="ver1"; aa=tst; tst="ver2"; bb=tst; tst="quit";                 ?<br>&gt; &gt;   3  -------   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -<br>&gt; &gt;        ? If:                                                                   ?<br>&gt; &gt;        Then: display;                                                          ?<br>&gt; &gt;   4  -------   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -   -<br>&gt; &gt;        ? If:                                                                   ?<br>&gt; &gt;        Then: end   <br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; The perl script :<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; #!/usr/bin/perl<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; my $string = ();<br>&gt; &gt; <br>&gt; &gt; <br>&gt; &gt; while ( ($string = &lt;STDIN&gt;) ne "quit\n" ) {<br>&gt; &gt;         chomp($string);<br>&gt; &gt;         if( "$string" eq "ver1"){<br>&gt; &gt;                 print "This is version 1\n";<br>&gt; &gt;         }<br>&gt; <br>&gt; Insert "else" here<br>&gt; <br>&gt; &gt;         if( "$string" eq "ver2"){<br>&gt; &gt;                 print "This is version 2\n";<br>&gt; &gt;         }<br>&gt; <br>&gt; Add a catchall "else" here:<br>&gt; <br>&gt;      else { print "Oops.  I didn't recognize \"$string\"\n"; }<br>&gt; <br>&gt; &gt; }<br>&gt; &gt; close(FILE);<br>&gt; &gt; The result should be that I can see on my screen the two texts coresponding to ver1 and ver2 in the dummy fields "aa" and "bb".<br>&gt; <br>&gt; But, what _was_ the result?<br>&gt; <br>&gt; -- <br>&gt; Kenneth Brody<br></div><br /><hr />Windows Live™ SkyDrive™: Get 25 GB of free online storage.   <a href='http://windowslive.com/online/skydrive?ocid=TXT_TAGLM_WL_SD_25GB_062009' target='_new'>Get it on your BlackBerry or iPhone.</a></body>
</html>