Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

new to procomm aspect, have a "capabilities question"

Status
Not open for further replies.

stevelitwak

Programmer
May 31, 2007
2
US
We are a unix shop using pc's with shared drives
and i want to use procomm to invoke actions
on unix and on the pc in one script.

i have successfully used the metakeys and keyboard editor
to separately invoke commands to unix (via send text) and
run programs to invoke notepad , wordpad and excel.

However, now I need one job/script to prompt user for a line #, send command to unix, run wordpad to edit the file
then command unix to pick up the file.

Is this doable within one Aspect Scripts ?
Can it be launched by a metakey ?
Can it be done in less than 4 years ? ( just kidding )

If so, a small skeleton example would be worth
several atta-boys/girls ... or, just a few notes
on which coimmands to use would be great

Our environment:
Procomm Plus 4.8 build 71
WIndows nt 5.01, servc pack 2
Aix

Thanks in advance

Steve

 
What your asking about looks like a simple process.

When you said 'run wordpad to edit the file.' Do you mean for the user to modify the file, or do you want a text file modified programatically (is that a word?)

It's very simple to have Aspect edit text files.

Post up a little more info, for instance, a sample of the commands you want sent to the remote host, and an example of the data you want to modify.
 
Thanks for your reply ...

Currently, we use Procom as a terminal emulator to
access unix from a pc on a multi user system.

I have defined some keyboard keys to issue forth
text strings .. For example, F9 is programmed to
issue the text CALL "C_SEARCH"^M

When F9 is pressed ( and the basic language interpreter has been started ), the text string is printed,
unix receives it and passes it thru to the basic
language interpreter, which executes code in basic.

Example # 2:
Have a file named TEST.txt which the basic language
program saves some info to be editted. The file resides
in a folder shared by unix and windows nt.

Have defined a meta-key of the type RUN PROGRAM
and have defined the code as:

C:\WORDPAD c:\TEST.txt

When this meta-key is clicked, Procomm issues
dos/msft command to windows to execute
WORDPAD and start using the file TEST.txt

WORDPAD begins and the contents of TEST.txt are
displayed and the editting can begin.

However, I want to combine both unix and windows
funtionality into one script in an attempt to have
Procomm be a bridge between unix and windows with
more complex procedures.

Another function I would like to perform, and this may
be impossible, is to issue a command from basic language
(under unix ) which Procomm would receive and act upon...

In some languages, you can issue a command that simulates
pressing a key... if the basic language could issue
a command that pressed a meta key, which procomm
interpreted and then executed, we could enrich
the unix capabilities.

Unix could , in effect, launch windows jobs by way of procomm ..

TIA

Steve Litwak ... tinkerer
 
Okay, if I'm understanding correctly:

I have defined some keyboard keys to issue forth
text strings .. For example, F9 is programmed to
issue the text CALL "C_SEARCH"^M

In Aspect (procomms scripting language) an example would be something like this.

Code:
proc main
string sXMit

sXMit = "C_SEARCH^M"
transmit sXMit

endproc

Then you can use the waitfor keyword to look for a specific response, of success or failure.

Prompting a user for input would look like the following:

Code:
string sTempString
sdlginput "Enter line#" "Input line#" sTempString DEFAULT
[code]

And to open notepad (I think replacing notepad with wordpad will do what you want):

[code]
run "notepad.exe c:\TEST.txt"          ; Run Windows NOTEPAD.

 
Another ASPECT user from the long-gone Symantec forum posted a method that uses Procomm's remote script command feature to launch commands in response to output from a Unix shell script. This might be another way to do what you are looking for. Go to and search for Unix to find the information from that user. There is a short example that shows how to launch Procomm's ASPECT editor from that shell script to get you started.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top