Compartir por


SessionStateSection.StateNetworkTimeout Propiedad

Definición

Obtiene o establece la cantidad de tiempo que la conexión de red entre el servidor web y el servidor de estado pueden permanecer inactivos.

public:
 property TimeSpan StateNetworkTimeout { TimeSpan get(); void set(TimeSpan value); };
[System.ComponentModel.TypeConverter(typeof(System.Configuration.TimeSpanSecondsOrInfiniteConverter))]
[System.Configuration.ConfigurationProperty("stateNetworkTimeout", DefaultValue="00:00:10")]
public TimeSpan StateNetworkTimeout { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.Configuration.TimeSpanSecondsOrInfiniteConverter))>]
[<System.Configuration.ConfigurationProperty("stateNetworkTimeout", DefaultValue="00:00:10")>]
member this.StateNetworkTimeout : TimeSpan with get, set
Public Property StateNetworkTimeout As TimeSpan

Valor de propiedad

El tiempo, en segundos, que la conexión de red entre el servidor web y el servidor de estado pueden permanecer inactivos antes de que se abandone la sesión. El valor predeterminado es 10 segundos.

Atributos

Ejemplos

En el ejemplo de código siguiente se muestra cómo obtener la StateNetworkTimeout propiedad . Consulte el ejemplo de código del tema de clase SessionStateSection para obtener información sobre cómo acceder al SessionStateSection objeto .

// Display the current StateNetworkTimeout property value.
Console.WriteLine("StateNetworkTimeout: {0}",
  sessionStateSection.StateNetworkTimeout);
' Display the current StateNetworkTimeout property value.
Console.WriteLine("StateNetworkTimeout: {0}", _
  sessionStateSection.StateNetworkTimeout)

Comentarios

Este sessionStateSection atributo es necesario cuando la Mode propiedad está establecida StateServeren .

Se aplica a