ALE.Sql.Sql.ExecuteReader C# (CSharp) Method

ExecuteReader() public method

public ExecuteReader ( SqlCommand cmd, SqlDataReader>.Action callback ) : Sql
cmd System.Data.SqlClient.SqlCommand
callback SqlDataReader>.Action
return Sql
        public Sql ExecuteReader(SqlCommand cmd, Action<Exception, SqlDataReader> callback)
        {
            if (callback == null) throw new ArgumentNullException("callback");
            cmd.Connection.Open();
            var state = new ExecuteReaderState(cmd, callback);
            cmd.BeginExecuteReader(EndExecuteReader, state);
            return this;
        }

Same methods

Sql::ExecuteReader ( string commandText, SqlDataReader>.Action callback ) : Sql
Sql::ExecuteReader ( string commandText, object args, SqlDataReader>.Action callback ) : Sql
Sql::ExecuteReader ( string commandText, object args, CommandType cmdType, SqlDataReader>.Action callback ) : Sql