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

SQL Anywhere 11.0.1 (中文) » MobiLink - 服务器管理 » MobiLink 服务器 API » 使用 .NET 编写同步脚本 » 用于 .NET 参考的 MobiLink 服务器 API » DownloadData 接口

 

GetDownloadTables 方法

语法
DownloadTableData[ ] GetDownloadTables( );
注释

获取此同步中要下载数据的所有表的数组。对此表执行的操作会发送到远程数据库。

返回值

下载表数据的数组。数组中表的顺序与远程的上载顺序相同。

示例

以下示例使用 DownloadData.GetDownloadTables 方法为当前同步获取 DownloadTableData 对象的一个数组。本示例假定您拥有一个名为 _cc 的 DBConnectionContext 实例。

// The method used for the handle_DownloadData event.
public void HandleDownload() { 
    // Get the DownloadData for the current synchronization.
    DownloadData my_dd = _cc.GetDownloadData();
  
    // Get an array of tables to set download operations.
    DownloadTableData[] download_tables = my_dd.GetDownloadTables();

    // Get the first table in the DownloadTableData array.
    DownloadTableData my_download_table = download_tables[0];
  
    // ...
}