This documentation is archived and is not being maintained.

DataContext.CommandTimeout Property

Increases the time-out period for queries that would otherwise time out during the default time-out period.

Namespace:  System.Data.Linq
Assembly:  System.Data.Linq (in System.Data.Linq.dll)

public int CommandTimeout { get; set; }

Property Value

Type: System.Int32
An integer value that represents seconds.

This property gets or sets the command time-out used to execute generated commands (IDbCommands). For more information, see CommandTimeout.

When this property is not set, the default value of CommandTimeout is used for query command execution. This default value is set by the storage provider. Note that some providers may throw exceptions if this value is set to a non-zero value.

.NET Framework

Supported in: 4, 3.5

.NET Framework Client Profile

Supported in: 4

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), 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.