RE: Windows Authentication : switching user

From: Simon Turmel (sturmel_at_polygon.ca)
Date: 04/05/04


Date: Mon, 05 Apr 2004 10:44:11 -0700

It's really simple. I use an hyperlink to reload the page with a new URL
parameter and then in my web page codebehind, I check if the parameter
is not null. If so, I send a 401 to force the reauthentication.

if( Request.QueryString["ChangeUser"] != null )
{
    Response.StatusCode = 401;
}

I get the windows authentication dialog, but I have to click OK 3 times
before it goes away. Apart from this, everything is fine, the user is
changed.

TIA,
Simon

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!



Relevant Pages

  • RE: Windows Authentication : switching user
    ... I'll do some more looking as soon as I get a chance, but just right off, it ... I use an hyperlink to reload the page with a new URL ... >parameter and then in my web page codebehind, ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: How to bring aspx code (in HTML view) to the aspx.vb code-behind?
    ... hyperlink works, other parameters, so that I can pass it info such as ... >> You don't use the script delimiters in codebehind. ... >> looks like you wish to fill a cart, which is a datagrid? ... Don't forget to close the reader... ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: HyperLink with IsPostBack= true
    ... Create some html instead of the HyperLink controls and in the generated html you can specify the querystring yourself. ... aspx page but with different query string, I pass the year and the month in the query string. ... Is it possible to put the IsPostBack value to true when I click on the HyperLink and reload the page with different query string? ...
    (microsoft.public.dotnet.framework.aspnet.webcontrols)
  • Hyperlink column in Datatable???
    ... I currently have the following datagrid but want to turn the name and email ... column into a hyperlink in the codebehind! ... Prev by Date: ...
    (microsoft.public.dotnet.framework.aspnet)
  • simple question
    ... i am creating Hyperlink control in the codebehind and adding it to ... the panel. ... HyperLink MyHyperLink = new HyperLink; ...
    (microsoft.public.dotnet.framework.aspnet)