.NET Framework Class Library LogoutAction Enumeration Indicates the page that the user will be directed to when he or she logs out of the Web site.
Namespace:
System.Web.UI.WebControls
Assembly:
System.Web (in System.Web.dll)

Syntax
Public Enumeration LogoutAction
public enum class LogoutAction

Members
| Member name | Description |
|---|
| Refresh | Reloads the current page with the user logged out. | | Redirect | Redirects the user to a specified URL. | | RedirectToLoginPage | Redirects the user to the login page defined in the site's configuration files (Machine.config and Web.config). |

Remarks
The LogoutAction enumeration members indicate the action taken when the user logs out of the Web site using the LoginStatus control.

Examples
The following code example shows how to set the LoginStatus..::.LogoutAction property using the LogoutAction enumeration.
<%@ Page Language="VB" AutoEventWireup="False" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html >
<head>
<title>ASP.NET Example</title>
</head>
<body>
<form id="form1" runat="server">
<asp:LoginStatus id="LoginStatus1" runat="server"
LogoutAction="RedirectToLoginPage" />
</form>
</body>
</html>
<%@ Page Language="C#" AutoEventWireup="False" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html >
<head>
<title>ASP.NET Example</title>
</head>
<body>
<form id="form1" runat="server">
<asp:LoginStatus id="LoginStatus1" runat="server"
LogoutAction="RedirectToLoginPage" />
</form>
</body>
</html>

Version Information
.NET FrameworkSupported in: 4, 3.5, 3.0, 2.0

Platforms
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role not supported), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

See Also
|
Bibliothèque de classes .NET Framework LogoutAction, énumération Indique la page vers laquelle l'utilisateur sera dirigé lorsqu'il se déconnecte du site Web.
Espace de noms :
System.Web.UI.WebControls
Assembly :
System.Web (dans System.Web.dll)

Syntaxe
Public Enumeration LogoutAction
public enum class LogoutAction

Membres
| Nom de membre | Description |
|---|
| Refresh | Recharge la page actuelle, l'utilisateur étant déconnecté. | | Redirect | Redirige l'utilisateur vers une URL spécifiée. | | RedirectToLoginPage | Redirige l'utilisateur vers la page de connexion définie dans les fichiers de configuration du site (Machine.config et Web.config). |

Notes
Les membres de l'énumération LogoutAction indiquent l'action exécutée lorsque l'utilisateur se déconnecte du site Web à l'aide du contrôle LoginStatus.

Exemples
L'exemple de code suivant illustre comment définir la propriété LoginStatus..::.LogoutAction à l'aide de l'énumération LogoutAction.
<%@ Page Language="VB" AutoEventWireup="False" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html >
<head>
<title>ASP.NET Example</title>
</head>
<body>
<form id="form1" runat="server">
<asp:LoginStatus id="LoginStatus1" runat="server"
LogoutAction="RedirectToLoginPage" />
</form>
</body>
</html>
<%@ Page Language="C#" AutoEventWireup="False" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html >
<head>
<title>ASP.NET Example</title>
</head>
<body>
<form id="form1" runat="server">
<asp:LoginStatus id="LoginStatus1" runat="server"
LogoutAction="RedirectToLoginPage" />
</form>
</body>
</html>

Informations de version
.NET FrameworkPris en charge dans : 4, 3.5, 3.0, 2.0

Plateformes
Windows 7, Windows Vista SP1 ou ultérieur, Windows XP SP3, Windows XP SP2 Édition x64, Windows Server 2008 (installation minimale non prise en charge), Windows Server 2008 R2 (installation minimale prise en charge avec SP1 ou version ultérieure), Windows Server 2003 SP2
Le .NET Framework ne prend pas en charge toutes les versions de chaque plateforme. Pour obtenir la liste des versions prises en charge, consultez Configuration requise du .NET Framework.

Voir aussi
|