Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Get UserName from Active Directory

Get UserName from Active Directory

Scheduled Pinned Locked Moved ASP.NET
windows-admintutorialquestion
4 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    macca24
    wrote on last edited by
    #1

    I want to be able to get the windows Username of the user on my system from Active directory. Anyone know how to do this? macca

    E P 2 Replies Last reply
    0
    • M macca24

      I want to be able to get the windows Username of the user on my system from Active directory. Anyone know how to do this? macca

      E Offline
      E Offline
      eyeseetee
      wrote on last edited by
      #2

      i dont think you can do this

      1 Reply Last reply
      0
      • M macca24

        I want to be able to get the windows Username of the user on my system from Active directory. Anyone know how to do this? macca

        P Offline
        P Offline
        Paddy Boyd
        wrote on last edited by
        #3

        It can be done, but it means granting appropriate privleges to the context under which your site runs, which is not always a good idea.

        A 1 Reply Last reply
        0
        • P Paddy Boyd

          It can be done, but it means granting appropriate privleges to the context under which your site runs, which is not always a good idea.

          A Offline
          A Offline
          Ariel Kazeed
          wrote on last edited by
          #4

          Sure it can be a mess... but in case you want to retrieve the username of whoever is using your app in the other side, I believe a simple My.User.Name in the codebehind may work.

          Kazz


          "Users are there to click on things, not think. Let the archs do the damn thinking."

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups