Solved

Can Global.Application_Start() get the URL?

Posted on 2011-02-10
4
1,514 Views
Last Modified: 2012-05-11
How would the Application_Start() method in the Global.asax file get the URL the user used to load to the program?

OR

How might the Global object find the username and password used to log onto a releated website of ours? I want to use Single Sign On but since the browser has the cookie locked down, I need the other program or the browser somehow provide this information to Global.Application_Start() on the second website to load.

Thanks,
newbieweb
0
Comment
Question by:newbieweb
  • 2
  • 2
4 Comments
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 500 total points
ID: 34864609
should be able to use :

System.Web.HttpContext.Current.Request.Url.AbsoluteUri.ToString();
0
 
LVL 29

Expert Comment

by:Paul Jackson
ID: 34864624
For the username I think this will work :

System.Web.HttpContext.Current.User.Identity.Name
0
 

Author Comment

by:newbieweb
ID: 34864715
The first one worked, but the User was null in the second one.
0
 

Author Closing Comment

by:newbieweb
ID: 34864731
I'll deal with the User later. Thanks.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now