Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (中文) » UltraLite - .NET 编程 » UltraLite .NET 2.0 API 参考 » ULCommand 类 » BeginExecuteNonQuery 方法

 

BeginExecuteNonQuery(AsyncCallback, Object) 方法

在已知回调过程和状态信息的情况下,启动由此 ULCommand 说明的 SQL 语句的异步执行。

语法
Visual Basic
Public Function BeginExecuteNonQuery( _
   ByVal callback As AsyncCallback, _
   ByVal stateObject As Object _
) As IAsyncResult
C#
public IAsyncResult BeginExecuteNonQuery(
   AsyncCallback callback,
   object stateObject
);
参数
  • callback   命令执行完成时调用的 System.AsyncCallback 委派。传递空值(在 Microsoft Visual Basic 中是 Nothing)表示不需要回调。

  • stateObject   传递给回调过程的用户定义状态对象。使用 System.IAsyncResult.AsyncState 属性从回调过程中检索此对象。

返回值

可只用于进行轮询、只用于等待结果或返回轮询和等待结果这两者的 System.IAsyncResult;调用 EndExecuteNonQuery(IAsyncResult)(返回受影响的行数)时也需要此值。

另请参见