×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Interacting with Attachmate dialog box at login

Interacting with Attachmate dialog box at login

Interacting with Attachmate dialog box at login

(OP)
I am starting to implement some scripting (in Excel/VBA) to interact with Attachmate EXTRA! X-Treme 9.3.
I can successfully create and open the session and I am able to send keys.

However, while the user name for the connection is stored, the password is not. I receive a dialog box prompting for the password and I have not figured out how to interact with this.
I am able to manually enter the password and resume my code; but how can I do this systematically?

Thanks for any guidance!

CODE --> VBA

Public oSys As ExtraSystem
Public oSess As ExtraSession
Public oScreen As ExtraScreen
Sub ConnectToAttachmate()
    Set oSys = CreateObject("Extra.System")
    
    If oSys Is Nothing Then
        MsgBox ("Could not create Extra.System...is E!PC installed on this machine?")
        Exit Sub
    End If
    
    If oSys.Sessions.Count = 0 Then
        Set oSess = oSys.Sessions.Open("C:\Users\ashenko\Desktop\apl\test.edp")
    Else
        Set oSess = oSys.Sessions(1)
    End If

    If (oSess Is Nothing) Then
        MsgBox "Could not create the Sessions collection object. Stopping macro playback."
        Stop
    End If

    If Not oSess.Visible Then oSess.Visible = True
End Sub

Sub Main()
    Call ConnectToAttachmate
    
    oSess.Activate
    Set oScreen = oSess.Screen
    oSess.Screen.SendKeys "<Enter>"
End Sub
 

RE: Interacting with Attachmate dialog box at login

Hi,

Quote:

I am starting to implement some scripting (in VBA)

What application are you coding your VBA in?

Skip,

glassesJust traded in my OLD subtlety...
for a NUance!tongue

RE: Interacting with Attachmate dialog box at login

(OP)
My apologies. I am using Excel and interacting with Attachmate EXTRA! X-Treme 9.3

RE: Interacting with Attachmate dialog box at login

Good choice, BTW! Suspected that, but just wanted to be certain.

Just use the control that you’d use in any other circumstance. I’ve use and ActiveX or Forms control, from your Developer menu. I’ve run all my screen scrapers from Excel, since my driver data was in Excel and my results went to Excel for my users and I much prefer to drive a Caddy than a Yugo.

BTW, born and raised in the Keystone State.

Skip,

glassesJust traded in my OLD subtlety...
for a NUance!tongue

RE: Interacting with Attachmate dialog box at login

(OP)
How do I pass this information to the password prompt from Attachmate?
Once I get passed that prompt (manually), I can interact with that session though Excel; but I am unable to figure how to send my password to that popup dialog box (in the screenshot) that Attachmate is bringing up. I am not sure how to set the focus on that rather than the main window.

And sadly, Fall foliage is abandoning us here in PA as the trees are pretty much baron. It was pretty for a few weeks.

RE: Interacting with Attachmate dialog box at login

Hmmmmm?

Never had a pop-up. Always had terminal interface to IBM mainframes where the emulator mimicked a green screen dumb terminal with login fields on screen.

Is there some way to start your session interface with a screen login rather than a control object? You call a startup program puts the control up. There may be another way to call up a screen form.

Not knowing your system, but I recall a /for I believe.

Skip,

glassesJust traded in my OLD subtlety...
for a NUance!tongue

RE: Interacting with Attachmate dialog box at login

(OP)
I was able to resolve this today.

For the benefit of others who come across the same problem:

The popup dialog of EXTRA! does not accept SendKeys sent to the ExtraSession object (in my case, called oSess).
However, you can use AppActivate in VBA by referencing the EXTRA! application by name and SendKeys to that to clear the pop-up prompt.

Then from there, you can SendKeys and otherwise interact with the session screen directly (in my case, oSess.Screen.SendKeys) as expected.

RE: Interacting with Attachmate dialog box at login

Great! And thanks for sharing your solution. That’s what Tek-Tips is all about.

Skip,

glassesJust traded in my OLD subtlety...
for a NUance!tongue

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close