Ejemplo n.º 1
0
 //Promotion Data
 private void PromotionData()
 {
     try
     {
         EclipsePOS.WPF.SystemManager.Data.promotionDataSet promotionDataSet = new  promotionDataSet();
         EclipsePOS.WPF.SystemManager.Data.promotionDataSetTableAdapters.promotionTableAdapter promotionTableAdapter = new  EclipsePOS.WPF.SystemManager.Data.promotionDataSetTableAdapters.promotionTableAdapter();
         promotionTableAdapter.Fill(promotionDataSet.promotion);
         promotionDataSet.WriteXml(View.OutputFolderPath() + "\\Promotion.xml", XmlWriteMode.WriteSchema);
     }
     catch (Exception e)
     {
         //Microsoft.Windows.Controls.MessageBox.Show(e.ToString());
     }
 }
Ejemplo n.º 2
0
        //Promotion
        private void PromotionData()
        {
            try
            {
                EclipsePOS.WPF.SystemManager.Data.promotionDataSet dataSetXml = new  promotionDataSet();
                dataSetXml.ReadXml(View.InputFolderPath() + "\\Promotion.xml", XmlReadMode.ReadSchema);

                EclipsePOS.WPF.SystemManager.Data.promotionDataSet dataSetRDB = new  promotionDataSet();
                EclipsePOS.WPF.SystemManager.Data.promotionDataSetTableAdapters.promotionTableAdapter tableAdapter = new  EclipsePOS.WPF.SystemManager.Data.promotionDataSetTableAdapters.promotionTableAdapter();
                tableAdapter.Fill(dataSetRDB.promotion);

                dataSetRDB.Merge(dataSetXml);
                tableAdapter.Update(dataSetRDB);
            }
            catch (Exception e)
            {
                //Microsoft.Windows.Controls.MessageBox.Show(e.ToString());
                return;
            }
        }