Welcome to Forums Sign in | Join | Help | Forums
in Search


Determining username

Last post 05-10-2006 3:52 PM by Hayden Muhl. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 05-09-2006 4:03 PM

    • Hayden Muhl
    • Not Ranked
    • Posts 4
    • Organization: Advocate Charitable Foundation

    Determining username

    Is there a way to determine the name of the user currently logged in? I'm trying to write a VBA macro that will prevent posted gifts from being deleted, which I have already figured out. I would like to use a conditional statement to allow the supervisor account to delete gifts, but can't find a way to determine if the current user is supervisor.
  • 05-09-2006 6:14 PM In reply to

    • Peter Falconer
    • Top 500 Contributor
    • Posts 36
    • Organization: Oxfam Australia
    • Products:  The Raiser's Edge

    Determining username

    Public Function GetTheUserName(ByVal Session As IBBSessionContext) As String Dim oservice As REServices Dim oCode As IBBUtilityCode On Error GoTo eh Set oservice = New REServices oservice.Init Session Set oCode = oservice GetTheUserName = oCode.GetUserName(Session.CurrentUserID) oservice.CloseDown Set oservice = Nothing Set oCode = Nothing Call with GetTheUserName(REApplication.SessionContext)
  • 05-10-2006 3:52 PM In reply to

    • Hayden Muhl
    • Not Ranked
    • Posts 4
    • Organization: Advocate Charitable Foundation

    Determining username

    Fantastic. Thank you.
Page 1 of 1 (3 items)