473,288 Members | 1,771 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,288 software developers and data experts.

Page.User.Identity.Name

Where does this function get the name from ?
reason i ask is, a user wanted their name changing on the domain,
i fixe everything else (email,login etc etc) but this function still
displays the old name

cheers

mark
May 19 '06 #1
4 4067
The .net uses the identity of the current login user. But It depends on the
kind of authentication you use. If you are using Windows based authentication
then it will use NT Domain user id, But in some cases your application is
also running under admin id, in this case you impersonate admin id to run
application. you may check ur web.config for it.

"luna" wrote:
Where does this function get the name from ?
reason i ask is, a user wanted their name changing on the domain,
i fixe everything else (email,login etc etc) but this function still
displays the old name

cheers

mark

May 19 '06 #2
cheers,

weird, seems to be windows auth

<authentication mode="Windows" />
<identity impersonate="true" />
still shows the wrong name, might just be the active directory
mark
"Altaf Al-Amin Najwani" <al**********@gmail.com> wrote in message
news:0D**********************************@microsof t.com...
The .net uses the identity of the current login user. But It depends on
the
kind of authentication you use. If you are using Windows based
authentication
then it will use NT Domain user id, But in some cases your application is
also running under admin id, in this case you impersonate admin id to run
application. you may check ur web.config for it.

"luna" wrote:
Where does this function get the name from ?
reason i ask is, a user wanted their name changing on the domain,
i fixe everything else (email,login etc etc) but this function still
displays the old name

cheers

mark

May 19 '06 #3
"Windows" means use the username IIS determines, so you must also configure
IIS. Probabaly what you need to do in IIS is disallow anonymous access.

The impersonate setting is unrelated to determining User.Identity.Name. It's
used for setting a thread token on the executing thread based upon IIS' user.
Chances are that you don't need or want that if you simply want to know who
the user is.

-Brock
http://staff.develop.com/ballen

cheers,

weird, seems to be windows auth

<authentication mode="Windows" />
<identity impersonate="true" />
still shows the wrong name, might just be the active directory

mark
"Altaf Al-Amin Najwani" <al**********@gmail.com> wrote in message
news:0D**********************************@microsof t.com...
The .net uses the identity of the current login user. But It depends
on
the
kind of authentication you use. If you are using Windows based
authentication
then it will use NT Domain user id, But in some cases your
application is
also running under admin id, in this case you impersonate admin id to
run
application. you may check ur web.config for it.
"luna" wrote:
Where does this function get the name from ?
reason i ask is, a user wanted their name changing on the domain,
i fixe everything else (email,login etc etc) but this function still
displays the old name
cheers

mark

May 19 '06 #4
anon access is disabled, integrated windows authenticion only
havent been back to check if its ok as the woman does my head in!
"Brock Allen" <ba****@NOSPAMdevelop.com> wrote in message
news:b8************************@msnews.microsoft.c om...
"Windows" means use the username IIS determines, so you must also
configure IIS. Probabaly what you need to do in IIS is disallow anonymous
access.

The impersonate setting is unrelated to determining User.Identity.Name.
It's used for setting a thread token on the executing thread based upon
IIS' user. Chances are that you don't need or want that if you simply want
to know who the user is.

-Brock
http://staff.develop.com/ballen

cheers,

weird, seems to be windows auth

<authentication mode="Windows" />
<identity impersonate="true" />
still shows the wrong name, might just be the active directory

mark
"Altaf Al-Amin Najwani" <al**********@gmail.com> wrote in message
news:0D**********************************@microsof t.com...
The .net uses the identity of the current login user. But It depends
on
the
kind of authentication you use. If you are using Windows based
authentication
then it will use NT Domain user id, But in some cases your
application is
also running under admin id, in this case you impersonate admin id to
run
application. you may check ur web.config for it.
"luna" wrote:

Where does this function get the name from ?
reason i ask is, a user wanted their name changing on the domain,
i fixe everything else (email,login etc etc) but this function still
displays the old name
cheers

mark


May 22 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Brian Conway | last post by:
Does anyone know how I can assign a Session variable to this? so that I can pull it back out on another page?
2
by: Jason Shohet | last post by:
I need to get the logged on user, and I'm using this code: label1.Text = Page.User.Identity.Name; Unfortunately there are some people at the organization who I cannot determine who they are,...
3
by: martin | last post by:
Hi, I have a website that runs under Annotmous access. I am trying to find out the account that the page is running under the line Response.Write("<hr>" & Page.User.Identity.Name & "<hr>") ...
0
by: Darrin | last post by:
I have a ASP.NET (using vb.net) application setup that allows someone to fill out an application form. The form goes across multiple pages (10) so on the first page I assign a unique ID and store...
0
by: Ben | last post by:
Hi - which of these two methods is preferred to determine the username of the current user? Ben
2
by: John | last post by:
Help! I've just spend the last three days researching and testing the following issue without any results. I have a test page setup to get the Windows logon name of the user. The site is a...
2
by: Abraham Andres Luna | last post by:
hello everyone, does anyone know why i can't access the HttpContext.Current.User.Identity.Name property in a .cs file? this is the index.aspx page: <%@ Page Language="C#" %> <script...
3
by: =?Utf-8?B?Q2hhcmxlc0E=?= | last post by:
hi folks, I've got XP pro service pack 2 VS 2005 TSE with ASP.net 2.0 and C# I'm doing an example from Stephen Walther's so far excellent book and he has a whole load of stuff to add the...
4
by: Doogie | last post by:
Hi, I am using HttpContext.Current.User.Identity.Name to get a user id from a web application. I then use that as part of a name of a cookie I'm writing. 30 minutes later I do a refresh of this...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: Aftab Ahmad | last post by:
So, I have written a code for a cmd called "Send WhatsApp Message" to open and send WhatsApp messaage. The code is given below. Dim IE As Object Set IE =...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.