irenavassilia
Programmer
- Jun 19, 2007
- 101
Hi Everyone,
I am creating a function that gets the Accpac User ID.
I cant seem to get it work properly, I am very new to VBA Accpac programming so I'm not sure if its my code that wrong or something else because I dont get any errors:
Here is my code, any help will be greatly appreaciated:
Private Sub Form_Load()
Dim Session As New AccpacSession
Dim SignOn As New AccpacSignonMgr
Dim mSessionMgr As New AccpacSessionManager.AccpacSessionMgr
Dim UserID As String
Set mSessionMgr = New AccpacSessionManager.AccpacSessionMgr
Set Session = New AccpacSession
With mSessionMgr
.ForceNewSignon = False
UserID = Session.UserID
End With
End Sub
The UserId is always null.
Regards,
Irena
I am creating a function that gets the Accpac User ID.
I cant seem to get it work properly, I am very new to VBA Accpac programming so I'm not sure if its my code that wrong or something else because I dont get any errors:
Here is my code, any help will be greatly appreaciated:
Private Sub Form_Load()
Dim Session As New AccpacSession
Dim SignOn As New AccpacSignonMgr
Dim mSessionMgr As New AccpacSessionManager.AccpacSessionMgr
Dim UserID As String
Set mSessionMgr = New AccpacSessionManager.AccpacSessionMgr
Set Session = New AccpacSession
With mSessionMgr
.ForceNewSignon = False
UserID = Session.UserID
End With
End Sub
The UserId is always null.
Regards,
Irena