<html>
<head>
<meta name="GENERATOR" content="SAPIEN Technologies PrimalScript 3.0">
<title>Document Title</title>
</head>
<body id="Bel">
<div id="Response"></div>
<h2>Test of a PerlScript function being called from VBScript</h2>
<p>
<input type="text" id="PipeCreate" value="">
<input type="button" onclick="PipeCreate(document.all.PipeCreate.value);" value="Create Pipe"><br>
<input id="WriteThis" type="text" size="15" value="">
<input type="button" onclick="WriteToPipe(document.all.WriteThis.value)" value="Write To Created Pipe">
<input type="button" onclick="ReadFromPipe" value="Read Pipe">
</p>
<form method="POST" action="" onsubmit="javascript:return false">
<p><input type="button" value="Close" onclick="javascript:self.close();"></p>
</form>
<p>
</p>
<iframe src="PerlServer.htm" id="PerlServ" style="height:0px;width:0px;border:0px"></iframe>
<script language="PerlScript">
use IO::Socket::INET;
use Win32:ipe;
$pipe = @_;
sub WriteToPipe {
$WhatToWrite= @_;
$OurPipe = new Win32:ipe->("$pipe"
$OurPipe->connect("$pipe"
$pipe->write("$WhatToWrite"
$OurPipe->close();
}
sub ReadFromPipe {
$OurPipe->connect("$pipe"
$Data = $OurPipe->read($pipe)
$DatRetVal=("This Is The Data:$Data\n"
$window->alert("$DatRetVal"
$OurPipe->close();
}
sub PipeCreate {
$OurPipe = new Win32:ipe("\\\\.\\Pipe\\$pipe"
}
sub sayHello {
# This function takes two parameters, creates a string
# from the parameters, and returns the string.
# get the two parameters into local variables
my ($strName, $strTime) = @_;
#now, create the return string.
$strRetVal="Hello $strName. The time is $strTime.";
# Return the string
$strRetVal;
}
</script>
<script language="PerlScript">
my @win =$window->alert("hello World!\n"
@win =$window->alert("The World is ours that know perl."
$window->alert(@win);
chomp($newdir = "C:\\"
chdir($newdir) || die "Cannot chdir to $newdir: $!";
foreach (<*>) {
$window->alert("$_\n"
}
</script>
<Script language="vbscript">
strOutput=sayHello("Visitor",Now & ""
Response.innerText= strOutput & " "
</script>
<!-- Insert HTML here -->
</body>
</html>
<head>
<meta name="GENERATOR" content="SAPIEN Technologies PrimalScript 3.0">
<title>Document Title</title>
</head>
<body id="Bel">
<div id="Response"></div>
<h2>Test of a PerlScript function being called from VBScript</h2>
<p>
<input type="text" id="PipeCreate" value="">
<input type="button" onclick="PipeCreate(document.all.PipeCreate.value);" value="Create Pipe"><br>
<input id="WriteThis" type="text" size="15" value="">
<input type="button" onclick="WriteToPipe(document.all.WriteThis.value)" value="Write To Created Pipe">
<input type="button" onclick="ReadFromPipe" value="Read Pipe">
</p>
<form method="POST" action="" onsubmit="javascript:return false">
<p><input type="button" value="Close" onclick="javascript:self.close();"></p>
</form>
<p>
</p>
<iframe src="PerlServer.htm" id="PerlServ" style="height:0px;width:0px;border:0px"></iframe>
<script language="PerlScript">
use IO::Socket::INET;
use Win32:ipe;
$pipe = @_;
sub WriteToPipe {
$WhatToWrite= @_;
$OurPipe = new Win32:ipe->("$pipe"
$OurPipe->connect("$pipe"
$pipe->write("$WhatToWrite"
$OurPipe->close();
}
sub ReadFromPipe {
$OurPipe->connect("$pipe"
$Data = $OurPipe->read($pipe)
$DatRetVal=("This Is The Data:$Data\n"
$window->alert("$DatRetVal"
$OurPipe->close();
}
sub PipeCreate {
$OurPipe = new Win32:ipe("\\\\.\\Pipe\\$pipe"
}
sub sayHello {
# This function takes two parameters, creates a string
# from the parameters, and returns the string.
# get the two parameters into local variables
my ($strName, $strTime) = @_;
#now, create the return string.
$strRetVal="Hello $strName. The time is $strTime.";
# Return the string
$strRetVal;
}
</script>
<script language="PerlScript">
my @win =$window->alert("hello World!\n"
@win =$window->alert("The World is ours that know perl."
$window->alert(@win);
chomp($newdir = "C:\\"
chdir($newdir) || die "Cannot chdir to $newdir: $!";
foreach (<*>) {
$window->alert("$_\n"
}
</script>
<Script language="vbscript">
strOutput=sayHello("Visitor",Now & ""
Response.innerText= strOutput & " "
</script>
<!-- Insert HTML here -->
</body>
</html>