public virtual NorthwindDataSet.CustOrdersDetailDataTable GetData(global::System.Nullable <int> OrderID)
 {
     this.Adapter.SelectCommand = this.CommandCollection[0];
     if ((OrderID.HasValue == true))
     {
         this.Adapter.SelectCommand.Parameters[1].Value = ((int)(OrderID.Value));
     }
     else
     {
         this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
     }
     NorthwindDataSet.CustOrdersDetailDataTable dataTable = new NorthwindDataSet.CustOrdersDetailDataTable();
     this.Adapter.Fill(dataTable);
     return(dataTable);
 }
        public virtual int Fill(NorthwindDataSet.CustOrdersDetailDataTable dataTable, global::System.Nullable <int> OrderID)
        {
            this.Adapter.SelectCommand = this.CommandCollection[0];
            if ((OrderID.HasValue == true))
            {
                this.Adapter.SelectCommand.Parameters[1].Value = ((int)(OrderID.Value));
            }
            else
            {
                this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value;
            }
            if ((this.ClearBeforeFill == true))
            {
                dataTable.Clear();
            }
            int returnValue = this.Adapter.Fill(dataTable);

            return(returnValue);
        }
コード例 #3
0
 public virtual NorthwindDataSet.CustOrdersDetailDataTable GetData(System.Nullable<int> OrderID) {
     this.Adapter.SelectCommand = this.CommandCollection[0];
     if ((OrderID.HasValue == true)) {
         this.Adapter.SelectCommand.Parameters[1].Value = ((int)(OrderID.Value));
     }
     else {
         this.Adapter.SelectCommand.Parameters[1].Value = System.DBNull.Value;
     }
     NorthwindDataSet.CustOrdersDetailDataTable dataTable = new NorthwindDataSet.CustOrdersDetailDataTable();
     this.Adapter.Fill(dataTable);
     return dataTable;
 }