CodeVerge.Net Beta


   Explore    Item Entry    Members      Register  Login  
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML

Free Download:




Zone: > NEWSGROUP > Asp.Net Forum > general_asp.net.security Tags:
Item Type: NewsGroup Date Entered: 7/14/2005 9:18:00 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 3 Views: 16 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
4 Items, 1 Pages 1 |< << Go >> >|
aellis
Asp.Net User
Intranet application -- find user "automatically"7/14/2005 9:18:00 AM

0/0

I am writing an intranet application in ASP.NET 2.0 which should automatically obtain a user's username.

The code below retrieves the username when I run in debug-mode through "Web Developer Express", but when I try to run the same code through IIS it is unable to retrieve the username.

Could anyone shed some light on this?

Regards,

Alex

http://localhost/src/
Welcome Unknown user.


http://localhost:1036/helpdesk/Default.aspx
Welcome D3MF2Q1J\alex.


using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class _Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
    }
    public String getUser()
    {
        return (Page.User.Identity.Name.Equals("") ? (HttpContext.Current.User.Identity.Name.Equals("") ? "" :HttpContext.Current.User.Identity.Name) : Page.User.Identity.Name);
    }
}


LuKiller
Asp.Net User
Re: Intranet application -- find user "automatically"7/14/2005 10:48:58 AM

0/0

Try changing the security configuration of the IIS.
LKZ:
.\Arrobianos/.
http://www.lukiller.net
Roland
Asp.Net User
Re: Intranet application -- find user "automatically"7/14/2005 10:55:00 AM

0/0

Hi aellis,

I think the simplest way to do this is:
Apply (perhaps on Masterpage) a LoginName Control from toolbox section "Login". I hope this is available in Web Developer Express, I am using Visual Studio 2005 Beta 2.
This control shows username automatically when Authentication is set to "Windows" and if it's set to "Forms", the control shows username after login.

If you need a string in your code, you can do it this way:
string CurrUser = Page.User.Identity.Name;

best regards
Roland


More Networks has been wiped out by Admins than any Hacker could do in a lifetime
Muffin77
Asp.Net User
Re: Intranet application -- find user "automatically"11/11/2005 9:08:08 AM

0/0

I am having the same problem, someone help?
4 Items, 1 Pages 1 |< << Go >> >|


Free Download:

Books:
Issues and Trends of Information Technology Management in Contemporary Organizations: 2002 Information Resources Management Association International Conference, Seattle, Washington, USA, May 19-22, 2002 Authors: Information Resources Management Association International Conference, Mehdi Khosrowpour, Information Resources Management Association, Pages: 1174, Published: 2002
Information Security Management Handbook Authors: Harold F. Tipton, Micki Krause, Pages: 3231, Published: 2007
Beginning Visual C# 2005 Authors: Karli Watson, Christian Nagel, Jacob Hammer Pedersen, Jon D. Reid, Morgan Skinner, Eric White, Pages: 1062, Published: 2006
IS Management Handbook Authors: Carol V. Brown, Heikki Topi, Pages: 788, Published: 1999
Secure PHP Development: Building 50 Practical Applications Authors: Mohammed J. Kabir, Pages: 875, Published: 2003
Occupational Outlook Handbook Authors: The United States Department of Labor, Pages: 696, Published: 2006
Proceedings of the IEEE 1997 National Aerospace and Electronics Conference, NAECON 1997: Held at the U.S. Air and Trade Show, Dayton, Ohio, July 14-17, 1997 Authors: Institute of Electrical & Electronics Engineers, Institute of Electrical and Electronics Engineers Dayton Section, IEEE National Aerospace, IEEE Aerospace and Electronic Systems Society, IEEE Aerospace and Electronic Systems Society, Electronics Conference, IEEE., Dayton Section, Pages: 1079, Published: 1997
Organic and Pervasive Computing--ARCS 2004: International Conference on Architecture of Computing Systems, Augsburg, Germany, March 23-26, 2004 : Proceedings Authors: Christian Müller-Schloer, Theo Ungerer, Bernhard Bauer, Pages: 337, Published: 2004
Macromedia Coldfusion MX Web Application Construction Kit: Web Application Construction Kit Authors: Ben Forta, Nate Weiss, Leon Chalnick, Angela C. Buraglia, Pages: 1500, Published: 2002
Software Testing and Continuous Quality Improvement: A Quality Framework for Software Testing Authors: William E. Lewis, Pages: 620, Published: 2000

Web:
MaxTech Brings Instant Internet/Intranet Access to Legacy ... With emulation, users can create their own intranet without having to rewrite or convert ... automatically select a chosen server to run applications. ...
Search and Search Engines — Prescient Digital Media - intranet ... by Carmine Porco — At most organizations the number one intranet user ... Dynamic composite applications can automatically respond to unknown needs such as ...
Recipe: Enabling Windows Authentication within an Intranet ASP.NET ... NET 2.0 SqlRoleProvider to map Windows users to custom application roles ...... are an internet user and not intranet, so it skips the automatic windows ...
Third-Generation Web Applications, Full-Service Intranets, EDI ... 3.5.1 User services; 3.5.2 Network services. 3.6 Intranet applications .... with rank-ordered, clickable, automatically hyperlinked search results. ...
Good Mobile Intranet Technical Overview - Find White Papers and ... Mobile users can request or submit information quickly and easily by using Good Mobile Intranet applications on a handheld, and receive responses while ...
ODESeW. Automatic Generation of Knowledge Portals for Intranets ... structure on this content that helps the user find knowledge assets. ... application: the Intranet and Extranet of the European funded project Esperonto. In ...
AUTOMATED ROAD ICE NOWCASTS AND INTERNET/INTRANET APPLICATION INTERNET/INTRANET APPLICATION. J. Shao and P. J. Lister .... User convenience, i.e., a use can get access to both the observation data and forecast ...
Intranet Software, Intranet Solution from NovoSolutions.com Our intranet applications are used in a variety of industries around the globe. ... End User Active Directory Authentication & Search - single sign on for ...
Besttoolbars.net: Internet Explorer Toolbar for Intranet ... With the cursor search feature users can quickly conduct a search on a word or ... The Intranet Toolbar allows you to instantly open intranet applications, ...
Claromentis Information Framework Management and Modular Solutions Claromentis framework and intranet software solutions, fully bespoke CMS and ... users with approval rights receive automatic notification that the page is ...

Videos:
iPhone in Enterprise The best phone for business. Ever. What makes iPhone a great business phone? Simple. The same features that make it a revolutionary mobile device. W...




Search This Site:










web hosting web matrix

billing system?

how to get parent method's name

variable as argument for sub routine

menubar using sitemap

date in asp.net and sql is different. pls help

sql installation problem

bug report: core module documents, "upload new file" don't display untill file location dropdownlist changed

these forums and dnn integrated less than $10

vs2003 or vs2005

smtpclient questions

menu control rendering

which file has the code for login

cdate("4-/4/4/4/4") please explain.........

how can i retrieve the userid in the createuserwizard?

join tables in datagrid

can i make an application method to kick off long stored proc?

custom membership and custom role provider problems

iexplore.exe-application error

error using rendercontrol

i cant make it work

delay upon initial view

differnce between java script and asp validation

errors on session timeout or application restart ...

web.config pages theme not working after publish

versioning causes you to lose all information stored in the profile

enterprise events module for dnn3 done. free download!

preserving source control history across migration

webproject reference in class lib

multiple word documents

 
All Times Are GMT