473,473 Members | 1,889 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

User ID

There is a routine in VB for Access that captures the NT Logon ID of the
user. Is there such a thing with .NET? Where can I find information about
capturing the logged on userID?

tia,
--
JMorrell
Jul 21 '05 #1
4 1507
SK
use request.servervariables("LOGON_USER")
This should give you DOMAINNAME\USERID,
Parse off the DOMAINNAME from the string.
Hope this helps.

SK

"JMorrell" wrote:
There is a routine in VB for Access that captures the NT Logon ID of the
user. Is there such a thing with .NET? Where can I find information about
capturing the logged on userID?

tia,
--
JMorrell

Jul 21 '05 #2
Thanks for the reply. I've tried it and now I'm having a problem parsing out
the domain. What's the trick to doing that? As you can tell, I'm new to the
dot NET world.

tia,
JMorrell

"SK" wrote:
use request.servervariables("LOGON_USER")
This should give you DOMAINNAME\USERID,
Parse off the DOMAINNAME from the string.
Hope this helps.

SK

"JMorrell" wrote:
There is a routine in VB for Access that captures the NT Logon ID of the
user. Is there such a thing with .NET? Where can I find information about
capturing the logged on userID?

tia,
--
JMorrell

Jul 21 '05 #3
Imports System.Environment
Private UserName As String = Environment.UserName

This is the simplest way.

"JMorrell" <JM******@discussions.microsoft.com> wrote in message
news:39**********************************@microsof t.com...
There is a routine in VB for Access that captures the NT Logon ID of the
user. Is there such a thing with .NET? Where can I find information
about
capturing the logged on userID?

tia,
--
JMorrell

Jul 21 '05 #4
This is too easy... Thanks

JMorrell

"Brian P. Hammer" <bhammer@le "DASH" wrote:
Imports System.Environment
Private UserName As String = Environment.UserName

This is the simplest way.

"JMorrell" <JM******@discussions.microsoft.com> wrote in message
news:39**********************************@microsof t.com...
There is a routine in VB for Access that captures the NT Logon ID of the
user. Is there such a thing with .NET? Where can I find information
about
capturing the logged on userID?

tia,
--
JMorrell


Jul 21 '05 #5

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

Similar topics

60
by: Fotios | last post by:
Hi guys, I have put together a flexible client-side user agent detector (written in js). I thought that some of you may find it useful. Code is here: http://fotios.cc/software/ua_detect.htm ...
3
by: zlst | last post by:
Many technological innovations rely upon User Interface Design to elevate their technical complexity to a usable product. Technology alone may not win user acceptance and subsequent marketability....
6
by: martin | last post by:
Hi, I am a web page and a web user control. My web user control is placed in my web page using the following directive <%@ Register TagPrefix="uc1" TagName="Header"...
1
by: Shourie | last post by:
I've noticed that none of the child controls events are firing for the first time from the dynamic user control. Here is the event cycle. 1) MainPage_load 2) User control1_Load user clicks a...
7
by: jsale | last post by:
I'm currently using ASP.NET with VS2003 and SQL Server 2003. The ASP.NET app i have made is running on IIS v6 and consists of a number of pages that allow the user to read information from the...
0
by: tony | last post by:
Hello! This is a rather long mail but it's a very interesting one. I hope you read it. I have tried several times to get an answer to this mail but I have not get any answer saying something...
2
by: rn5a | last post by:
Assume that a user control (MyUC.ascx) encapsulates 2 TextBoxes with the IDs 'txt1' & 'txt2' respectively. To use this user control in an ASPX page, the following Register directive will be...
1
by: Carlettus | last post by:
Dear All, sorry but I'm not sure if this is the right place to post my problem. I was using the following asp code to create users in Active Directory. Suddenly, and I don't know the reason, users...
0
by: rbukkara | last post by:
Hi, I have got the following error while trying to add a user in the LDAP Directory. javax.naming.NameNotFoundException: ; remaining name 'uid=vassila,ou=People,dc=cs,dc=uno,dc=edu' I have...
9
by: Gordon | last post by:
I want to add a feature to a project I'm working on where i have multiple users set up on my Postgres database with varying levels of access. At the bare minimum there will be a login user who...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.