当前位置: 首页>>代码示例>>C#>>正文


C# System.Data.DataSet.ReadXml方法代码示例

本文整理汇总了C#中System.Data.DataSet.ReadXml方法的典型用法代码示例。如果您正苦于以下问题:C# System.Data.DataSet.ReadXml方法的具体用法?C# System.Data.DataSet.ReadXml怎么用?C# System.Data.DataSet.ReadXml使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.Data.DataSet的用法示例。


在下文中一共展示了System.Data.DataSet.ReadXml方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Process

		internal static void Process (List<string> assemblies, string outputPath)
		{
			List<string> valid_config_files = new List<string> ();
			foreach (string assembly in assemblies) {
				string assemblyConfig = assembly + ".config";
				if (File.Exists (assemblyConfig)) {
					XmlDocument doc = new XmlDocument ();
					try {
						doc.Load (assemblyConfig);
					} catch (XmlException) {
						doc = null;
					}
					if (doc != null)
						valid_config_files.Add (assemblyConfig);
				}
			}
			
			if (valid_config_files.Count == 0)
				return;

			string first_file = valid_config_files [0];
			System.Data.DataSet dataset = new System.Data.DataSet ();
			dataset.ReadXml (first_file);
			valid_config_files.Remove (first_file);
			
			foreach (string config_file in valid_config_files) {
				System.Data.DataSet next_dataset = new System.Data.DataSet ();
				next_dataset.ReadXml (config_file);
				dataset.Merge (next_dataset);
			}
			dataset.WriteXml (outputPath + ".config");
		}
开发者ID:transformersprimeabcxyz,项目名称:cecil-old,代码行数:32,代码来源:ConfigMerger.cs

示例2: GetAllRecordsFromXML

 public void GetAllRecordsFromXML()
 {
     System.Data.DataSet ds = new System.Data.DataSet();
     ds.ReadXml(Server.MapPath("Login.xml"));
     GridView1.DataSource = ds;
     GridView1.DataBind();
 }
开发者ID:pkgod7,项目名称:windowsphone-sprmalaysia,代码行数:7,代码来源:Login.aspx.cs

示例3: GetBatchData

        private string GetBatchData()
        {
            var assembly = System.Reflection.Assembly.GetExecutingAssembly();
            string resourceName = "Processors.BBPS.CreditCard.Data.BatchData.xml";

            using (System.IO.Stream strm = assembly.GetManifestResourceStream(resourceName))
            {

                System.Data.DataSet orginalBatch = new System.Data.DataSet();
                System.Data.DataSet refund = new System.Data.DataSet();

                refund.Tables.Add(new System.Data.DataTable());

                var x = orginalBatch.ReadXml(strm);

                var dr = orginalBatch.Tables[0].CreateDataReader();
                refund.Tables[0].Columns.Add(new System.Data.DataColumn("transactionid"));
                refund.Tables[0].Columns.Add(new System.Data.DataColumn("referenceTransactionid"));
                refund.Tables[0].Columns.Add(new System.Data.DataColumn("amount"));

                while (dr.Read())
                {
                    var drow = refund.Tables[0].NewRow();
                    string refTrxId, amount;

                    refTrxId = dr.GetString(0);
                    amount = dr.GetString(6);

                    drow.ItemArray = new String[] { Guid.NewGuid().ToString(), refTrxId, amount };

                    refund.Tables[0].Rows.Add(drow);

                }

                using (System.IO.StringWriter sw = new System.IO.StringWriter(new System.Text.StringBuilder()))
                {
                    List<string> columns = new List<string>();

                    foreach (System.Data.DataColumn d in refund.Tables[0].Columns)
                    {
                        columns.Add(d.ColumnName);
                    }

                    sw.WriteLine(string.Join(",", columns.ToArray()));

                    foreach (System.Data.DataRow _dr in refund.Tables[0].Rows)
                    {
                        sw.WriteLine(string.Join(",", _dr.ItemArray));
                    }

                    return sw.GetStringBuilder().ToString();
                }

            }
        }
开发者ID:shovelheadfxe,项目名称:DevLab,代码行数:55,代码来源:Batch.cs

示例4: Process

        internal static void Process(ILRepack repack)
        {
            try
            {
                var validConfigFiles = new List<string>();
                foreach (string assembly in repack.MergedAssemblyFiles)
                {
                    string assemblyConfig = assembly + ".config";
                    if (File.Exists(assemblyConfig))
                    {
                        var doc = new XmlDocument();
                        doc.Load(assemblyConfig);
                        validConfigFiles.Add(assemblyConfig);
                    }
                }

                if (validConfigFiles.Count == 0)
                    return;

                string firstFile = validConfigFiles[0];
                var dataset = new System.Data.DataSet();
                dataset.ReadXml(firstFile);
                validConfigFiles.Remove(firstFile);

                foreach (string configFile in validConfigFiles)
                {
                    var nextDataset = new System.Data.DataSet();
                    nextDataset.ReadXml(configFile);
                    dataset.Merge(nextDataset);
                }
                dataset.WriteXml(repack.OutputFile + ".config");
            }
            catch (Exception e)
            {
                repack.ERROR("Failed to merge configuration files: " + e);
            }
        }
开发者ID:peters,项目名称:il-repack,代码行数:37,代码来源:ConfigMerger.cs

示例5: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     if ((this.DetermineSchemaSerializationMode(reader) == System.Data.SchemaSerializationMode.IncludeSchema)) {
         this.Reset();
         System.Data.DataSet ds = new System.Data.DataSet();
         ds.ReadXml(reader);
         if ((ds.Tables["ListaCampos"] != null)) {
             base.Tables.Add(new ListaCamposDataTable(ds.Tables["ListaCampos"]));
         }
         if ((ds.Tables["MetodoConsulta"] != null)) {
             base.Tables.Add(new MetodoConsultaDataTable(ds.Tables["MetodoConsulta"]));
         }
         if ((ds.Tables["ClasseCRUD"] != null)) {
             base.Tables.Add(new ClasseCRUDDataTable(ds.Tables["ClasseCRUD"]));
         }
         if ((ds.Tables["Metodo"] != null)) {
             base.Tables.Add(new MetodoDataTable(ds.Tables["Metodo"]));
         }
         if ((ds.Tables["Versao"] != null)) {
             base.Tables.Add(new VersaoDataTable(ds.Tables["Versao"]));
         }
         this.DataSetName = ds.DataSetName;
         this.Prefix = ds.Prefix;
         this.Namespace = ds.Namespace;
         this.Locale = ds.Locale;
         this.CaseSensitive = ds.CaseSensitive;
         this.EnforceConstraints = ds.EnforceConstraints;
         this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
         this.InitVars();
     }
     else {
         this.ReadXml(reader);
         this.InitVars();
     }
 }
开发者ID:ViniciusConsultor,项目名称:testeacontep,代码行数:34,代码来源:EstruturaSaveRAD.Designer.cs

示例6: parseIntoDOM

		/// <summary>Parses profile string into DOM document </summary>
		private System.Xml.XmlDocument parseIntoDOM(System.String profileString)
		{
			if (this.alwaysValidate)
				profileString = insertDoctype(profileString);
			System.Xml.XmlDocument doc = null;
			try
			{
				lock (this)
				{
                    XmlTextReader reader = new XmlTextReader(new System.IO.MemoryStream(new System.Text.ASCIIEncoding().GetBytes(profileString)));
                    System.Data.DataSet data = new System.Data.DataSet();
                    data.ReadXml(reader);
                    doc = new XmlDataDocument(data);
				}
			}
			catch (System.Xml.XmlException se)
			{
				throw new NuGenProfileException("SAXException parsing message profile: " + se.Message);
			}
			catch (System.IO.IOException ioe)
			{
				throw new NuGenProfileException("IOException parsing message profile: " + ioe.Message);
			}
			return doc;
		}
开发者ID:xuchuansheng,项目名称:GenXSource,代码行数:26,代码来源:NuGenProfileParser.cs

示例7: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     if ((this.DetermineSchemaSerializationMode(reader) == System.Data.SchemaSerializationMode.IncludeSchema)) {
         this.Reset();
         System.Data.DataSet ds = new System.Data.DataSet();
         ds.ReadXml(reader);
         if ((ds.Tables["tblDoktorBilgisiDVO"] != null)) {
             base.Tables.Add(new tblDoktorBilgisiDVODataTable(ds.Tables["tblDoktorBilgisiDVO"]));
         }
         if ((ds.Tables["tblTaniBilgisiDVO"] != null)) {
             base.Tables.Add(new tblTaniBilgisiDVODataTable(ds.Tables["tblTaniBilgisiDVO"]));
         }
         if ((ds.Tables["tblHastaYatisBilgisi"] != null)) {
             base.Tables.Add(new tblHastaYatisBilgisiDataTable(ds.Tables["tblHastaYatisBilgisi"]));
         }
         if ((ds.Tables["tblCocukBilgisi"] != null)) {
             base.Tables.Add(new tblCocukBilgisiDataTable(ds.Tables["tblCocukBilgisi"]));
         }
         if ((ds.Tables["tblMalzemeBilgisi"] != null)) {
             base.Tables.Add(new tblMalzemeBilgisiDataTable(ds.Tables["tblMalzemeBilgisi"]));
         }
         if ((ds.Tables["tblTedaviIslemBilgisi"] != null)) {
             base.Tables.Add(new tblTedaviIslemBilgisiDataTable(ds.Tables["tblTedaviIslemBilgisi"]));
         }
         if ((ds.Tables["tblBransGorusBilgisi"] != null)) {
             base.Tables.Add(new tblBransGorusBilgisiDataTable(ds.Tables["tblBransGorusBilgisi"]));
         }
         this.DataSetName = ds.DataSetName;
         this.Prefix = ds.Prefix;
         this.Namespace = ds.Namespace;
         this.Locale = ds.Locale;
         this.CaseSensitive = ds.CaseSensitive;
         this.EnforceConstraints = ds.EnforceConstraints;
         this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
         this.InitVars();
     }
     else {
         this.ReadXml(reader);
         this.InitVars();
     }
 }
开发者ID:AydinSakar,项目名称:Naz.Hastane,代码行数:40,代码来源:f00_ds.Designer.cs

示例8: ExecuteQuery

    private void ExecuteQuery(/*bool ShowWindow*/)
    {
      if (dsData != null)
      {
        dsData = null;
      }

      dsData = new System.Data.DataSet();
      dsData.ReadXmlSchema("c:\\data.xsd");
      dsData.ReadXml("c:\\data.xml");

      if (_reporte != null)
      {
        //        _reporte.SQL = SQL;
        //        _reporte.ReloadData();
        _reporte.ReloadData(dsData);
      }

      if (_reporteRegadores != null)
      {
        ReporteRegadoresDataset rep = new ReporteRegadoresDataset();
        rep.Process(dsData);
        _reporteRegadores.ReloadData(rep.DataSet);
      }

      if (_rawDataForm != null)
      {
        _rawDataForm.DataSource = dsData;
      }
    }
开发者ID:diegowald,项目名称:intellitrack,代码行数:30,代码来源:DataRetriever.cs

示例9: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     if ((this.DetermineSchemaSerializationMode(reader) == System.Data.SchemaSerializationMode.IncludeSchema)) {
         this.Reset();
         System.Data.DataSet ds = new System.Data.DataSet();
         ds.ReadXml(reader);
         if ((ds.Tables["Cash"] != null)) {
             base.Tables.Add(new CashDataTable(ds.Tables["Cash"]));
         }
         if ((ds.Tables["DocumentType"] != null)) {
             base.Tables.Add(new DocumentTypeDataTable(ds.Tables["DocumentType"]));
         }
         if ((ds.Tables["InvoiceMaster"] != null)) {
             base.Tables.Add(new InvoiceMasterDataTable(ds.Tables["InvoiceMaster"]));
         }
         if ((ds.Tables["InvoiceDetail"] != null)) {
             base.Tables.Add(new InvoiceDetailDataTable(ds.Tables["InvoiceDetail"]));
         }
         if ((ds.Tables["Periods"] != null)) {
             base.Tables.Add(new PeriodsDataTable(ds.Tables["Periods"]));
         }
         if ((ds.Tables["ReceiptDetail"] != null)) {
             base.Tables.Add(new ReceiptDetailDataTable(ds.Tables["ReceiptDetail"]));
         }
         if ((ds.Tables["ReceiptMaster"] != null)) {
             base.Tables.Add(new ReceiptMasterDataTable(ds.Tables["ReceiptMaster"]));
         }
         if ((ds.Tables["ReceiptRemains"] != null)) {
             base.Tables.Add(new ReceiptRemainsDataTable(ds.Tables["ReceiptRemains"]));
         }
         if ((ds.Tables["Product"] != null)) {
             base.Tables.Add(new ProductDataTable(ds.Tables["Product"]));
         }
         if ((ds.Tables["Remains"] != null)) {
             base.Tables.Add(new RemainsDataTable(ds.Tables["Remains"]));
         }
         if ((ds.Tables["Stock"] != null)) {
             base.Tables.Add(new StockDataTable(ds.Tables["Stock"]));
         }
         if ((ds.Tables["LocalSetting"] != null)) {
             base.Tables.Add(new LocalSettingDataTable(ds.Tables["LocalSetting"]));
         }
         if ((ds.Tables["Orders"] != null)) {
             base.Tables.Add(new OrdersDataTable(ds.Tables["Orders"]));
         }
         if ((ds.Tables["inventoryMaster"] != null)) {
             base.Tables.Add(new inventoryMasterDataTable(ds.Tables["inventoryMaster"]));
         }
         if ((ds.Tables["inventoryDetails"] != null)) {
             base.Tables.Add(new inventoryDetailsDataTable(ds.Tables["inventoryDetails"]));
         }
         this.DataSetName = ds.DataSetName;
         this.Prefix = ds.Prefix;
         this.Namespace = ds.Namespace;
         this.Locale = ds.Locale;
         this.CaseSensitive = ds.CaseSensitive;
         this.EnforceConstraints = ds.EnforceConstraints;
         this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
         this.InitVars();
     }
     else {
         this.ReadXml(reader);
         this.InitVars();
     }
 }
开发者ID:vpjulia,项目名称:Salvia,代码行数:64,代码来源:MDataSet.Designer.cs

示例10: readXML

        /// <summary>
        /// ��XML�ĵ�
        /// </summary>
        /// <param name="name">Ҫȡ�������ļ��е�ָ������Դ������,��:��ϵͳ "oldsystem" </param>
        public ConfigStruct readXML(string name)
        {
            try
            {
                //�����µĽṹ����
                ConfigStruct cfg = new ConfigStruct();

                //����һ���µ�dataset
                System.Data.DataSet ds = new System.Data.DataSet();

                //�ж��ļ��Ƿ����,��������ʾ���󲢷���һ���յĽṹ����
                if (System.IO.File.Exists(AppDomain.CurrentDomain.BaseDirectory.TrimEnd(new char[] {'\\'}) +"\\"+_FileName))
                {
                    //����������ȡconfig.xml�ļ�������
                    ds.ReadXml(AppDomain.CurrentDomain.BaseDirectory.TrimEnd(new char[] {'\\'}) +"\\" +_FileName);
                }
                else
                {
                    //                    System.Windows.Forms.MessageBox.Show("config.xml�ļ�������!" , "����",
                    //                        System.Windows.Forms.MessageBoxButtons.OK ,
                    //                        System.Windows.Forms.MessageBoxIcon.Warning);
                    return new ConfigStruct();
                }

                //�жϱ��Ƿ����,��������ʾ���󲢷���һ���յĽṹ����
                if (ds.Tables.IndexOf(name.ToUpper())== -1 )
                {
                    //                    System.Windows.Forms.MessageBox.Show("��config.xml�в����ҵ���ص�����Դ��������Ϣ!" , "����",
                    //                        System.Windows.Forms.MessageBoxButtons.OK ,
                    //                        System.Windows.Forms.MessageBoxIcon.Warning);
                    return new ConfigStruct();
                }

                SymmetricMethod sm = new SymmetricMethod();

            //                cfg.hostAddress = "CIT16-PC";
            //cfg.userName   ="sa";
            //cfg.password   ="111111";

            //cfg.DBName = "AutoUpDateData";

                //������ȡ��ֵ
                cfg.hostAddress = sm.Decrypto(ds.Tables[name.ToUpper()].Select("key='" + sm.Encrypto(str_HA) + "'")[0]["value"].ToString());
                cfg.userName = sm.Decrypto(ds.Tables[name.ToUpper()].Select("key='" + sm.Encrypto(str_UN) + "'")[0]["value"].ToString());
                cfg.password = sm.Decrypto(ds.Tables[name.ToUpper()].Select("key='" + sm.Encrypto(str_PWD) + "'")[0]["value"].ToString());
                cfg.DBName = sm.Decrypto(ds.Tables[name.ToUpper()].Select("key='" + sm.Encrypto(str_DBN) + "'")[0]["value"].ToString());

                ds.Dispose();

                return cfg;
            }
            catch//(Exception exp)
            {
                //System.Windows.Forms.MessageBox.Show(exp.Message);
                return new ConfigStruct();
            }
        }
开发者ID:dalinhuang,项目名称:qqhelp-heimu360,代码行数:61,代码来源:clsDBOperation.cs

示例11: LoadFromXmlTable

        /// <summary>
        /// this will load the database assuming a table with each 'rule' on a row
        /// This is generally used by the fRulesInspector in edit mode
        /// </summary>
        /// <param name="sFile"></param>
        public void LoadFromXmlTable(string sFile)
        {
            System.Data.DataSet ds = new System.Data.DataSet();
            ds.ReadXml(sFile);

            // now load the rules
            foreach (System.Data.DataRow row in ds.Tables[0].Rows)
            {
                Add(new Relationship(row["A"].ToString(),
                    row["Relation"].ToString(),
                    row["B"].ToString(),
                    row["Comment"].ToString(),
                    (double)row["Weight"],
                     (int)row["Priority"],
                    false

                ));
            }

            // try to make super generic with reflection
        }
开发者ID:BrentKnowles,项目名称:YourOtherMind,代码行数:26,代码来源:KnowledgeBase.cs

示例12: WebCEP

            /// <summary>  
            /// WebService para Busca de CEP  
            ///  </summary>  
            /// <param  name="CEP"></param>  
            public WebCEP(string CEP)
            {
                _uf = "";
                _cidade = "";
                _bairro = "";
                _tipo_lagradouro = "";
                _lagradouro = "";
                _resultado = "0";
                _resultato_txt = "CEP não encontrado";

                //Cria um DataSet  baseado no retorno do XML
                System.Data.DataSet ds = new System.Data.DataSet();
                ds.ReadXml("http://cep.republicavirtual.com.br/web_cep.php?cep=" + CEP.Replace("-", "").Trim() + "&formato=xml");

                if (ds != null)
                {
                    if (ds.Tables[0].Rows.Count > 0)
                    {
                        _resultado = ds.Tables[0].Rows[0]["resultado"].ToString();
                        switch (_resultado)
                        {
                            case "1":
                                _uf = ds.Tables[0].Rows[0]["uf"].ToString().Trim();
                                _cidade = ds.Tables[0].Rows[0]["cidade"].ToString().Trim();
                                _bairro = ds.Tables[0].Rows[0]["bairro"].ToString().Trim();
                                _tipo_lagradouro = ds.Tables[0].Rows[0]["tipo_logradouro"].ToString().Trim();
                                _lagradouro = ds.Tables[0].Rows[0]["logradouro"].ToString().Trim();
                                _resultato_txt = "CEP completo";
                                break;
                            case "2":
                                _uf = ds.Tables[0].Rows[0]["uf"].ToString().Trim();
                                _cidade = ds.Tables[0].Rows[0]["cidade"].ToString().Trim();
                                _bairro = "";
                                _tipo_lagradouro = "";
                                _lagradouro = "";
                                _resultato_txt = "CEP  único";
                                break;
                            default:
                                _uf = "";
                                _cidade = "";
                                _bairro = "";
                                _tipo_lagradouro = "";
                                _lagradouro = "";
                                _resultato_txt = "CEP não  encontrado";
                                break;
                        }
                    }
                }
                //Exemplo do retorno da  WEB
                //<?xml version="1.0"  encoding="iso-8859-1"?>
                //<webservicecep>
                //<uf>RS</uf>
                //<cidade>Porto  Alegre</cidade>
                //<bairro>Passo  D'Areia</bairro>
                //<tipo_logradouro>Avenida</tipo_logradouro>
                //<logradouro>Assis Brasil</logradouro>
                //<resultado>1</resultado>
                //<resultado_txt>sucesso - cep  completo</resultado_txt>
                //</webservicecep>
            }
开发者ID:EmersonBessa,项目名称:FluxusWeb,代码行数:64,代码来源:Util.cs

示例13: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     if ((this.DetermineSchemaSerializationMode(reader) == System.Data.SchemaSerializationMode.IncludeSchema)) {
         this.Reset();
         System.Data.DataSet ds = new System.Data.DataSet();
         ds.ReadXml(reader);
         if ((ds.Tables["Categories"] != null)) {
             base.Tables.Add(new CategoriesDataTable(ds.Tables["Categories"]));
         }
         if ((ds.Tables["CustomerCustomerDemo"] != null)) {
             base.Tables.Add(new CustomerCustomerDemoDataTable(ds.Tables["CustomerCustomerDemo"]));
         }
         if ((ds.Tables["CustomerDemographics"] != null)) {
             base.Tables.Add(new CustomerDemographicsDataTable(ds.Tables["CustomerDemographics"]));
         }
         if ((ds.Tables["Customers"] != null)) {
             base.Tables.Add(new CustomersDataTable(ds.Tables["Customers"]));
         }
         if ((ds.Tables["Employees"] != null)) {
             base.Tables.Add(new EmployeesDataTable(ds.Tables["Employees"]));
         }
         if ((ds.Tables["EmployeeTerritories"] != null)) {
             base.Tables.Add(new EmployeeTerritoriesDataTable(ds.Tables["EmployeeTerritories"]));
         }
         if ((ds.Tables["Order Details"] != null)) {
             base.Tables.Add(new Order_DetailsDataTable(ds.Tables["Order Details"]));
         }
         if ((ds.Tables["Orders"] != null)) {
             base.Tables.Add(new OrdersDataTable(ds.Tables["Orders"]));
         }
         if ((ds.Tables["Products"] != null)) {
             base.Tables.Add(new ProductsDataTable(ds.Tables["Products"]));
         }
         if ((ds.Tables["Region"] != null)) {
             base.Tables.Add(new RegionDataTable(ds.Tables["Region"]));
         }
         if ((ds.Tables["Shippers"] != null)) {
             base.Tables.Add(new ShippersDataTable(ds.Tables["Shippers"]));
         }
         if ((ds.Tables["Suppliers"] != null)) {
             base.Tables.Add(new SuppliersDataTable(ds.Tables["Suppliers"]));
         }
         if ((ds.Tables["Territories"] != null)) {
             base.Tables.Add(new TerritoriesDataTable(ds.Tables["Territories"]));
         }
         if ((ds.Tables["Alphabetical list of products"] != null)) {
             base.Tables.Add(new Alphabetical_list_of_productsDataTable(ds.Tables["Alphabetical list of products"]));
         }
         if ((ds.Tables["Category Sales for 1997"] != null)) {
             base.Tables.Add(new Category_Sales_for_1997DataTable(ds.Tables["Category Sales for 1997"]));
         }
         if ((ds.Tables["Current Product List"] != null)) {
             base.Tables.Add(new Current_Product_ListDataTable(ds.Tables["Current Product List"]));
         }
         if ((ds.Tables["Customer and Suppliers by City"] != null)) {
             base.Tables.Add(new Customer_and_Suppliers_by_CityDataTable(ds.Tables["Customer and Suppliers by City"]));
         }
         if ((ds.Tables["Invoices"] != null)) {
             base.Tables.Add(new InvoicesDataTable(ds.Tables["Invoices"]));
         }
         if ((ds.Tables["Order Details Extended"] != null)) {
             base.Tables.Add(new Order_Details_ExtendedDataTable(ds.Tables["Order Details Extended"]));
         }
         if ((ds.Tables["Order Subtotals"] != null)) {
             base.Tables.Add(new Order_SubtotalsDataTable(ds.Tables["Order Subtotals"]));
         }
         if ((ds.Tables["Orders Qry"] != null)) {
             base.Tables.Add(new Orders_QryDataTable(ds.Tables["Orders Qry"]));
         }
         if ((ds.Tables["Product Sales for 1997"] != null)) {
             base.Tables.Add(new Product_Sales_for_1997DataTable(ds.Tables["Product Sales for 1997"]));
         }
         if ((ds.Tables["Products Above Average Price"] != null)) {
             base.Tables.Add(new Products_Above_Average_PriceDataTable(ds.Tables["Products Above Average Price"]));
         }
         if ((ds.Tables["Products by Category"] != null)) {
             base.Tables.Add(new Products_by_CategoryDataTable(ds.Tables["Products by Category"]));
         }
         if ((ds.Tables["Quarterly Orders"] != null)) {
             base.Tables.Add(new Quarterly_OrdersDataTable(ds.Tables["Quarterly Orders"]));
         }
         if ((ds.Tables["Sales by Category"] != null)) {
             base.Tables.Add(new Sales_by_CategoryDataTable(ds.Tables["Sales by Category"]));
         }
         if ((ds.Tables["Sales Totals by Amount"] != null)) {
             base.Tables.Add(new Sales_Totals_by_AmountDataTable(ds.Tables["Sales Totals by Amount"]));
         }
         if ((ds.Tables["Summary of Sales by Quarter"] != null)) {
             base.Tables.Add(new Summary_of_Sales_by_QuarterDataTable(ds.Tables["Summary of Sales by Quarter"]));
         }
         if ((ds.Tables["Summary of Sales by Year"] != null)) {
             base.Tables.Add(new Summary_of_Sales_by_YearDataTable(ds.Tables["Summary of Sales by Year"]));
         }
         if ((ds.Tables["CustOrderHist"] != null)) {
             base.Tables.Add(new CustOrderHistDataTable(ds.Tables["CustOrderHist"]));
         }
         if ((ds.Tables["CustOrdersDetail"] != null)) {
             base.Tables.Add(new CustOrdersDetailDataTable(ds.Tables["CustOrdersDetail"]));
         }
         if ((ds.Tables["CustOrdersOrders"] != null)) {
             base.Tables.Add(new CustOrdersOrdersDataTable(ds.Tables["CustOrdersOrders"]));
//.........这里部分代码省略.........
开发者ID:ehershey,项目名称:development,代码行数:101,代码来源:NorthwindDataSet.Designer.cs

示例14: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     if ((this.DetermineSchemaSerializationMode(reader) == System.Data.SchemaSerializationMode.IncludeSchema)) {
         this.Reset();
         System.Data.DataSet ds = new System.Data.DataSet();
         ds.ReadXml(reader);
         if ((ds.Tables["PACK_ID"] != null)) {
             base.Tables.Add(new PACK_IDDataTable(ds.Tables["PACK_ID"]));
         }
         if ((ds.Tables["EXPORT_NOTES_HEAD"] != null)) {
             base.Tables.Add(new EXPORT_NOTES_HEADDataTable(ds.Tables["EXPORT_NOTES_HEAD"]));
         }
         if ((ds.Tables["SHIPPING_INSTR_HEAD"] != null)) {
             base.Tables.Add(new SHIPPING_INSTR_HEADDataTable(ds.Tables["SHIPPING_INSTR_HEAD"]));
         }
         if ((ds.Tables["PICKING_INSTR_HEAD"] != null)) {
             base.Tables.Add(new PICKING_INSTR_HEADDataTable(ds.Tables["PICKING_INSTR_HEAD"]));
         }
         if ((ds.Tables["DELIVERY_INSTR_HEAD"] != null)) {
             base.Tables.Add(new DELIVERY_INSTR_HEADDataTable(ds.Tables["DELIVERY_INSTR_HEAD"]));
         }
         if ((ds.Tables["SPECIAL_INSTR_HEAD"] != null)) {
             base.Tables.Add(new SPECIAL_INSTR_HEADDataTable(ds.Tables["SPECIAL_INSTR_HEAD"]));
         }
         if ((ds.Tables["CUSTOMER_INSTR_HEAD"] != null)) {
             base.Tables.Add(new CUSTOMER_INSTR_HEADDataTable(ds.Tables["CUSTOMER_INSTR_HEAD"]));
         }
         if ((ds.Tables["LABEL_INSTR_HEAD"] != null)) {
             base.Tables.Add(new LABEL_INSTR_HEADDataTable(ds.Tables["LABEL_INSTR_HEAD"]));
         }
         if ((ds.Tables["CARRIER_INST_HEAD"] != null)) {
             base.Tables.Add(new CARRIER_INST_HEADDataTable(ds.Tables["CARRIER_INST_HEAD"]));
         }
         if ((ds.Tables["INVOICE_UDF_HEAD"] != null)) {
             base.Tables.Add(new INVOICE_UDF_HEADDataTable(ds.Tables["INVOICE_UDF_HEAD"]));
         }
         if ((ds.Tables["UDF_HEAD"] != null)) {
             base.Tables.Add(new UDF_HEADDataTable(ds.Tables["UDF_HEAD"]));
         }
         if ((ds.Tables["UDF_HEADER"] != null)) {
             base.Tables.Add(new UDF_HEADERDataTable(ds.Tables["UDF_HEADER"]));
         }
         if ((ds.Tables["HANDLING_INSTR_HEAD"] != null)) {
             base.Tables.Add(new HANDLING_INSTR_HEADDataTable(ds.Tables["HANDLING_INSTR_HEAD"]));
         }
         if ((ds.Tables["PACK_ID_LINE_ITEM"] != null)) {
             base.Tables.Add(new PACK_ID_LINE_ITEMDataTable(ds.Tables["PACK_ID_LINE_ITEM"]));
         }
         if ((ds.Tables["EXPORT_NOTES_DETAIL"] != null)) {
             base.Tables.Add(new EXPORT_NOTES_DETAILDataTable(ds.Tables["EXPORT_NOTES_DETAIL"]));
         }
         if ((ds.Tables["SHIPPING_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new SHIPPING_INSTR_DETAILDataTable(ds.Tables["SHIPPING_INSTR_DETAIL"]));
         }
         if ((ds.Tables["PICKING_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new PICKING_INSTR_DETAILDataTable(ds.Tables["PICKING_INSTR_DETAIL"]));
         }
         if ((ds.Tables["DELIVERY_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new DELIVERY_INSTR_DETAILDataTable(ds.Tables["DELIVERY_INSTR_DETAIL"]));
         }
         if ((ds.Tables["SPECIAL_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new SPECIAL_INSTR_DETAILDataTable(ds.Tables["SPECIAL_INSTR_DETAIL"]));
         }
         if ((ds.Tables["CUSTOMER_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new CUSTOMER_INSTR_DETAILDataTable(ds.Tables["CUSTOMER_INSTR_DETAIL"]));
         }
         if ((ds.Tables["HANDLING_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new HANDLING_INSTR_DETAILDataTable(ds.Tables["HANDLING_INSTR_DETAIL"]));
         }
         if ((ds.Tables["UID_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new UID_INSTR_DETAILDataTable(ds.Tables["UID_INSTR_DETAIL"]));
         }
         if ((ds.Tables["CONFIG_INSTR_DETAIL"] != null)) {
             base.Tables.Add(new CONFIG_INSTR_DETAILDataTable(ds.Tables["CONFIG_INSTR_DETAIL"]));
         }
         if ((ds.Tables["MAXKIT_DETAIL"] != null)) {
             base.Tables.Add(new MAXKIT_DETAILDataTable(ds.Tables["MAXKIT_DETAIL"]));
         }
         if ((ds.Tables["UDF_DET"] != null)) {
             base.Tables.Add(new UDF_DETDataTable(ds.Tables["UDF_DET"]));
         }
         if ((ds.Tables["UDF_DETAIL"] != null)) {
             base.Tables.Add(new UDF_DETAILDataTable(ds.Tables["UDF_DETAIL"]));
         }
         if ((ds.Tables["HP_PN_COMPONENTS"] != null)) {
             base.Tables.Add(new HP_PN_COMPONENTSDataTable(ds.Tables["HP_PN_COMPONENTS"]));
         }
         if ((ds.Tables["BOX"] != null)) {
             base.Tables.Add(new BOXDataTable(ds.Tables["BOX"]));
         }
         if ((ds.Tables["SERIAL_NUM"] != null)) {
             base.Tables.Add(new SERIAL_NUMDataTable(ds.Tables["SERIAL_NUM"]));
         }
         this.DataSetName = ds.DataSetName;
         this.Prefix = ds.Prefix;
         this.Namespace = ds.Namespace;
         this.Locale = ds.Locale;
         this.CaseSensitive = ds.CaseSensitive;
         this.EnforceConstraints = ds.EnforceConstraints;
         this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
         this.InitVars();
//.........这里部分代码省略.........
开发者ID:wra222,项目名称:testgit,代码行数:101,代码来源:Schema_Pack_List_001_20080923_bck.cs

示例15: ReadXmlSerializable

 protected override void ReadXmlSerializable(System.Xml.XmlReader reader) {
     this.Reset();
     System.Data.DataSet ds = new System.Data.DataSet();
     ds.ReadXml(reader);
     if ((ds.Tables["Products"] != null)) {
         base.Tables.Add(new ProductsDataTable(ds.Tables["Products"]));
     }
     if ((ds.Tables["Orders"] != null)) {
         base.Tables.Add(new OrdersDataTable(ds.Tables["Orders"]));
     }
     if ((ds.Tables["Suppliers"] != null)) {
         base.Tables.Add(new SuppliersDataTable(ds.Tables["Suppliers"]));
     }
     if ((ds.Tables["Shippers"] != null)) {
         base.Tables.Add(new ShippersDataTable(ds.Tables["Shippers"]));
     }
     if ((ds.Tables["Customers"] != null)) {
         base.Tables.Add(new CustomersDataTable(ds.Tables["Customers"]));
     }
     if ((ds.Tables["Categories"] != null)) {
         base.Tables.Add(new CategoriesDataTable(ds.Tables["Categories"]));
     }
     if ((ds.Tables["Order Details"] != null)) {
         base.Tables.Add(new Order_DetailsDataTable(ds.Tables["Order Details"]));
     }
     if ((ds.Tables["Employees"] != null)) {
         base.Tables.Add(new EmployeesDataTable(ds.Tables["Employees"]));
     }
     this.DataSetName = ds.DataSetName;
     this.Prefix = ds.Prefix;
     this.Namespace = ds.Namespace;
     this.Locale = ds.Locale;
     this.CaseSensitive = ds.CaseSensitive;
     this.EnforceConstraints = ds.EnforceConstraints;
     this.Merge(ds, false, System.Data.MissingSchemaAction.Add);
     this.InitVars();
 }
开发者ID:BackupTheBerlios,项目名称:mbunit-svn,代码行数:37,代码来源:NorthwindDataSet.Designer.cs


注:本文中的System.Data.DataSet.ReadXml方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。