Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How do I abort from Global.Session_Start()?

Posted on 2011-02-11
6
Medium Priority
?
285 Views
Last Modified: 2012-05-11
If the user doesnot have access to website, I want to end it right there, if possible.

How might I do this?

Can I redirect to my error page?

Thanks,
newbieweb
0
Comment
Question by:newbieweb
  • 2
  • 2
  • 2
6 Comments
 
LVL 33

Accepted Solution

by:
Todd Gerbert earned 1000 total points
ID: 34875249
Yes, you can redirect to an error page and call Session.Abandon() there.
0
 

Author Comment

by:newbieweb
ID: 34875286
I can not call Redirect(). IntelliSense does not see it.

Must I prefix it with something?
0
 
LVL 33

Assisted Solution

by:Todd Gerbert
Todd Gerbert earned 1000 total points
ID: 34875337
Response.Redirect() or System.Web.HttpContext.Current.Response.Redirect().
0
Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

 
LVL 61

Assisted Solution

by:HainKurt
HainKurt earned 1000 total points
ID: 34875346
try

Rsponse.End()
0
 
LVL 61

Assisted Solution

by:HainKurt
HainKurt earned 1000 total points
ID: 34875349
or use

Server.Transfer("error.aspx")
0
 

Author Closing Comment

by:newbieweb
ID: 34916372
Thanks.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

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

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…
In real business world data are crucial and sometimes data are shared among different information systems. Hence, an agreeable file transfer protocol need to be established.
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Loops Section Overview

916 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