<% Dim strPageName strPageName = "AddUsersToMBP.asp" PutState "strRightFrameASPFolderName", "Publisher\ManageUsers" PutState "strRightFrameASPName", strPageName Dim strUsers Dim objUsersWO Dim arrUsers Dim objUsersRO Dim rsFromUser Dim strFromUserName Dim strFromUserEmail Dim strSubject Dim strBodyText '*** Fetch the list of selected users strUsers = Request("strSelectedUsers") '*** Invoke method to add the selected users to the current instance (role = GridName_USER) Set objUsersWO = Server.CreateObject("ChvCITCUserMgr.clsUsersWO") objUsersWO.AddUsersToInstanceWithOneRole gstrAppInstId, gstrAppInstAbbr, strUsers, _ UCase(gstrMBPName) & "_USER" If Err.Number <> 0 Then HandleError Err.Number, Err.source, Err.description, strPageName '*** Get the sending user's info. Set objUsersRO = Server.CreateObject("ChvCITCUserMgr.clsUsersRO") Set rsFromUser = objUsersRO.rsGetUserInfo(gstrUserId) If Err.number <> 0 Then Call HandleError(Err.number,Err.Source,Err.Description, strPageName) strFromUserName = rsFromUser.Fields("first_name").Value & " " & _ rsFromUser.Fields("last_name").Value strFromUserEmail = rsFromUser.Fields("email").Value & "" '*** Format the message info. strSubject = "Publisher Grid Invitation" strBodyText = _ "Subject: Please Join My eQuest Publisher Grid" & vbCRLF & _ vbCRLF & _ "I have added you as a user of my eQuest Publisher grid, " & gstrMBPName & ", " & _ "in the " & gstrAppInstName & " instance (collection of grids)." & vbCRLF & _ "You can use the link below to access your own start page, where you will" & vbCRLF & _ "find our grid has been automatically added to your list." & vbCRLF & _ vbCRLF & _ "To access your start page, just click here " & vbCRLF & _ "or type in equest-chevron.com in your browser address field." & vbCRLF & _ vbCRLF & _ rsFromUser.Fields("first_name").Value & " " & _ rsFromUser.Fields("last_name").Value & vbCRLF & _ rsFromUser.Fields("email").Value & vbCRLF & _ rsFromUser.Fields("phone").Value & vbCRLF & _ vbCRLF & _ "eQuest Publisher is a secure web application for sharing information" & vbCRLF & _ "over the " & gstrCOMPANY_NAME & " intranet and the internet. " & vbCRLF & _ gstrCOMPANY_NAME & " users can find out more about Publisher," & vbCRLF & _ "including training materials, at the Publisher Information Center " & vbCRLF & _ " website." '*** Send email message to the selected users arrUsers = Split(strUsers,",") Call strSendEmailToGroupOfUsers(strFromUserName, strFromUserEmail, arrUsers, _ strSubject, strBodyText) '*** Destroy objects and redirect back to the ManageUsers Page If Not (objUsersWO Is Nothing) Then Set objUsersWO = Nothing If Not (objUsersRO Is Nothing) Then Set objUsersRO = Nothing Response.Redirect "ManageUsers.asp" %>