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

Reflection unable to read existing sessions

Reflection unable to read existing sessions

Reflection unable to read existing sessions

I'm getting started with Reflection 2014 and the new object model and I'm running into an issue when trying to open a new terminal session. Right now I'm just playing around to get comfortable with the new model so I can start doing some actual work.

    'I open the current Application object and frame
    Set m_oApp = GetObject(, "Attachmate_Reflection_Objects_Framework.ApplicationObject")
    Set m_oFrame = m_oApp.GetObject("Frame")
    'I create a terminal from my default session file
    Set m_oTerminal = m_oApp.CreateControl(SESSIONS & CPI)
    'It fails here because it can't read the file even though this is the same file I created the current session from.
    Set m_oView = m_oFrame.CreateView(m_oTerminal)
    m_oFrame.Visible = True 

anybody else run into this so far?

RE: Reflection unable to read existing sessions

Unfortunately, what you gave me is using Reflection from several versions ago(2006). We upgraded to Reflections 2014, and I'm trying to document how to work with the very latest object model. I did finally get it to work, though.

Private m_oApp As Attachmate_Reflection_Objects_Framework.ApplicationObject
Private m_oFrame As Attachmate_Reflection_Objects.Frame
Private m_oIbmTerminal As Attachmate_Reflection_Objects_Emulation_IbmHosts.IbmTerminal
Private m_oView As Attachmate_Reflection_Objects.View
Private m_oIBMScreen As Attachmate_Reflection_Objects_Emulation_IbmHosts.IbmScreen
Private m_oScreenNav As clsScreenNav

Private m_iClient As Integer
Private m_oUser As clsUser

Public Sub Login(envEnvironment As Environment)
    Set m_oApp = GetObject("Reflection Workspace")
    Set m_oFrame = m_oApp.GetObject("Frame")
    Set m_oIbmTerminal = m_oApp.CreateControl(ThisIbmTerminal.SessionFilePath)
    Set m_oView = m_oFrame.CreateView(m_oIbmTerminal)
    m_oView.titleText = Me.Client
    Set m_oIBMScreen = m_oIbmTerminal.screen
    'Now Log in the user to the session in question
End Sub

As background our users log into the same host but for different clients. Each client has their own view with its own log in and so forth. This along with a client collection class lets me open multiple client sessions from a single session file. It works slick.

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