System.Data.Generic
DataSourceExecuteObjectT Method |
Executes the query, and returns a object by the type T.
Namespace: System.Data.Generic
Assembly: System.Data.Generic (in System.Data.Generic.dll) Version: 1.9.5473.30542 (1.9.5473.2392)

public T ExecuteObject<T>( string SQL ) where T : class
Public Function ExecuteObject(Of T As Class) ( SQL As String ) As T
public: generic<typename T> where T : ref class T ExecuteObject( String^ SQL )
member ExecuteObject : SQL : string -> 'T when 'T : not struct
Parameters
- SQL
- Type: SystemString
SQL statement to execute.
Type Parameters
- T
- Type of object to return.
Return Value
Type: TObject of type T.

Exception | Condition |
---|---|
ArgumentNullException | In case the SQL is null. |
SqlException | In case the underlying connection cause an exception. |

