Gets or sets the isolation level used for any transaction. Set only after the connection is open.
[Visual Basic] Public Property IsolationLevel As IsolationLevel [C#] public IsolationLevel IsolationLevel {get; set;} [C++] public: __property IsolationLevel get_IsolationLevel(); public: __property void set_IsolationLevel(IsolationLevel); [JScript] public function get IsolationLevel() : IsolationLevel; public function set IsolationLevel(IsolationLevel);
One of the IsolationLevel values. The default value is Unspecified.
Exception Type | Condition |
---|---|
InvalidIsolationLevel | The value set is not one of the IsolationLevel values. |
If the connection is closed, the IsolationLevel property is set to Unspecified.
Note This is the only property other than Database that can be set when the connection is open.
The following example shows how to create a connection and set many of its properties.
ADOConnection Class | ADOConnection Members | System.Data.ADO Namespace | ConnectionTimeout | Database | ConnectionString | DataSource | UserID | Password