VBA to OpenVMS and I'm lost
VBA to OpenVMS and I'm lost
(OP)
I have been reading the Attachmate documentation, trying code and using Google for about 2 weeks. The questions I see online are advanced. I just need to know the steps to connect from VBScript or VBA to work with OpenVMS. I have also tried connecting to OpenVMS from inside of the VBA editor in the menu choice that is in Attachmate. I don't know the place to enter the UserName and PW.
Do I need to set something up in Attachmate before I start to write the code?
Maybe I stepped into this attempt in the middle or I'm missing some concept.
In VBA I am using
Set oR = CreateObject(Session2.xxxxx) I don't have the code in front of me right now.
OR.xxxx
OR.xxxx
OR. Connect
The connect keeps asking for the Password. I cannot find a place to set the Password.
I'm thinking that once I am connected, then I can use the
.Session methods and properties
Am I on the right track?
Thanks,
Kevin
Do I need to set something up in Attachmate before I start to write the code?
Maybe I stepped into this attempt in the middle or I'm missing some concept.
In VBA I am using
Set oR = CreateObject(Session2.xxxxx) I don't have the code in front of me right now.
OR.xxxx
OR.xxxx
OR. Connect
The connect keeps asking for the Password. I cannot find a place to set the Password.
I'm thinking that once I am connected, then I can use the
.Session methods and properties
Am I on the right track?
Thanks,
Kevin
RE: VBA to OpenVMS and I'm lost
Never used a terminal emulator to interface with OpenVMS, which I assume is a VAX mainframe system.
But Extra is Extra.
Here's some code I've used to establish an Attachmate!Extra session via Excel VBA. (FIRST, I set a reference to the Attachmate Extra Object Library in the Excel VBA Editor.)...
CODE
Option Explicit 'you must have a reference set for Attachmate EXTRA! n.m Object Library 'runs with Form ufmPassword Public oSystem As ExtraSystem Public oSessions As ExtraSessions Public oSess As ExtraSession Public oScrn As ExtraScreen Sub IMS_Login Set oSystem = CreateObject("Extra.System") If oSystem.Sessions.Count = 0 Then Set oSess = oSystem.Sessions.Open("C:\Program Files\E!PC\Sessions\Mainframe.edp") Else Set oSess = oSystem.ActiveSession End If '...... End Sub
So if there is NO session opened already, it opens the emulator otherwise uses the active session.
The password is most likely to the OpenVMS system. What you need to do is based on the login screen. You probably have a Username and PWD, eacs at row and column coordinates. So your code must PutString() these two string values at the appropriate r,c. See HELP for PutString syntax.
This is code for an automatic login I used on my IMS system. It required acquiring the password in a variable via a form...
CODE
Skip,
for a NUance!
RE: VBA to OpenVMS and I'm lost
I appreciate the reply.
Yes OpenMVS is for the old VAX.
I don't know what I should have in this file: ("C:\Program Files\E!PC\Sessions\Mainframe.edp")
Do I make an Excel UserForm put a button on it and call one of these pieces of code you supplied?
What does this mean? How do I do this? : 'you must have a reference set for Attachmate EXTRA! n.m Object Library
'runs with Form ufmPassword
I noticed Extra while searching for Attachmate information.
When do I use With Session that I see all over the place?
You can tell from my questions that I am still lost.
Any guidance to get me on track to communicating with VAX will be useful.
Thanks,
Kevin
RE: VBA to OpenVMS and I'm lost
Your emulator session has a path and filename. It was so long ago that I figured out how to find that, I couldn't tell you the method. But that's where to begin.
Then what Attachmate application are you using? Extra, Reflections???
Have you consulted the HELP for your application? Attachmate web site?
Skip,
Just traded in my OLD subtlety...
for a NUance!
RE: VBA to OpenVMS and I'm lost
I am using Attachmate. I saw mention of "Extra" when searching online for Reflections information. I didn't know that it was a separate product.
I don't know how to create or find the emulator Session.
The attachmate documentation is not clear to me. I cannot tell when I am creating the Session and when I can start using the Session object.
Thanks,
Kevin
RE: VBA to OpenVMS and I'm lost
There ought to be some way to identify the path/filename of the session you manually started. Right-click the application and explore the properties.
Skip,
Just traded in my OLD subtlety...
for a NUance!