×
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

Get Login Position

Get Login Position

Get Login Position

(OP)
Hi,
We have developed several scripts but there comes new requirement where User don't want to input and re-input their Ellipse Login Information. So, we provide a new Login form and user types input here. However, several users have more than one positions and we don't want user to input the position themselves.
Does anyone here know how to get the Position information and put it to the Login information as in a Listbox?

Here is the code we currently use:

Set objMIMS = New MIMSXServer
    objMIMS.Initialise
    objMIMS.ServerConnect True
    objMIMS.RegistryGetDefaultProfile
        
    objMIMS.SendLoginBlock True, True, UCase(Trim(frmDownload.txtUsername.Text)), UCase(Trim(frmDownload.txtPassword.Text)),
UCase(Trim(frmDownload.txtDistrict.Text)),
UCase(Trim(frmDownload.txtPosition.Text))

TIA.

RE: Get Login Position

Hi waxman,

Not sure if this will help you as this is just bits of code I've used when switching between different MIMS logins using the "MIMS.Login" service (I've never actually used "SendLoginBlock" method).

But hopefully if nothing else it will give you a starter for 10

Please note that this should really just be considered pseudo-code as it doesn't have declarations, tidying code or errror handlers.

CODE


Set objLoginReply = objMIMS.SendLoginBlock True, True, UCase(Trim(frmDownload.txtUsername.Text)), UCase(Trim(frmDownload.txtPassword.Text)), UCase(Trim(frmDownload.txtDistrict.Text)), UCase(Trim(frmDownload.txtPosition.Text))

'
' Insert code here to extract returned attributes "LoginOkFlag", "PositionRequiredFlag" from objLoginReply
'

'
' If the "LoginOkFlag" = "N" and "PositionRequiredFlag" = "Y"
' Then run the following code.
'

Set objMimsBlock = objMIMS.Blocks.New("RetrievePosBlock")
Set objMimsRequest = objMimsBlock.Requests.New("RetrievePosRequest")

objMimsRequest.AddFieldNameValue MIMSX_FLAG_SERVICE, "MIMS.RetrievePositions"
objMimsRequest.AddFieldNameValue MIMSX_FLAG_REPLYLIST, "Position,PositionTitle"
objMimsRequest.AddFieldNameValue MIMSX_FLAG_MAXINST, "50"

Set objMimsReply = objMimsBlock.Send

'
' Extract positions from objMimsReply
' Display them in ComboBox etc
'

Reply back to the forum if you have any other queries and I'll try to help.

Cheers,

Glenn

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