public void LoadKioskData(string filename) { this.kioskFilename = filename; dataAccess.ReadKioskFile(filename); if (!File.Exists(kioskMonthlyBackupFilename)) { var products = new ObservableCollection <Product>(dataAccess.Products); XpsDocument doc = new XpsDocument(kioskMonthlyBackupFilename, System.IO.FileAccess.ReadWrite); XpsDocumentWriter writer = XpsDocument.CreateXpsDocumentWriter(doc); IDocumentPaginatorSource document = new StockPrintFlowDocument(products); writer.Write(document.DocumentPaginator); doc.Close(); } }
public void LoadKioskData(string filename) { this.kioskFilename = filename; dataAccess.ReadKioskFile(filename); }