コード例 #1
0
ファイル: SerializeDemo.xaml.cs プロジェクト: Daoting/dt
        /// <summary>
        /// 返回多个Table
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        async void GetTableList(object sender, RoutedEventArgs e)
        {
            List <Table> tbls = await AtTest.GetTableList();

            StringBuilder sb = new StringBuilder();

            sb.AppendFormat("调用成功,共有{0}个DataTable:\r\n", tbls.Count);
            foreach (var tbl in tbls)
            {
                foreach (var row in tbl)
                {
                    foreach (var cell in row.Cells)
                    {
                        sb.AppendFormat("{0}:{1}    ", cell.ID, cell.Val);
                    }
                    sb.AppendLine();
                }
                sb.AppendLine();
                sb.AppendLine();
            }
            _tbInfo.Text = sb.ToString();
        }