private void BeginPrint(object sender, BeginPrintEventArgs e) { tryCount = 0; currentPage = 0; isPrinting = false; isProcessing = false; PrintingPageText.Text = "Start"; PrintingProgressPanel.Visibility = Visibility.Visible; Debug.WriteLine("Start to print"); }
private void pdoc_BeginPrint(object sender, BeginPrintEventArgs e) { Diagram diagram = this.Diagram; if (diagram == null) { return; } diagram.Cursor = Cursors.Wait; }
private void pdoc_BeginPrint(object sender, BeginPrintEventArgs e) { Diagram diagram = this.Diagram; if (diagram == null) { return; } this.EffectivePageCount = 0; // uninitialized this.PageIndex = 0; if (this.Parts != null && this.Parts.FirstOrDefault() != null) { this.PartsToPrint = new HashSet <Part>(this.Parts); } else { this.PartsToPrint = null; } diagram.Cursor = Cursors.Wait; }
private void PrintingStartedHandler(object sender, BeginPrintEventArgs e) { ////Now that the print page has been initialized it can just be removed from its container, ////it does not need to be readed because it only needs to initialize in the visual tree once. ////All other layout updates happen in the PrintDocument. ////NOTE:If you do not have the print page be part of the visual tree initially the first print job performed will not update correclty and therefore will not look correct. _gridContainer.Children.Clear(); //Set datacontext so bindings still function correctly _printPage.DataContext = ControlToPrint.DataContext; _parent = ControlToPrint.Parent; //Right now we are assuming the control is in a Grid, possibly change this in the furture //The control needs to be removed from the UI because it can only have one parent at any given time. (_parent as Grid).Children.Remove(ControlToPrint); _printPage.Child = ControlToPrint; _curOffset = 0.0; _totalPages = null; }
/// <summary> /// This event is used to set busy and printing status and also display message that print has started. /// </summary> private void PrintDocument_BeginPrint(object sender, BeginPrintEventArgs e) { IsBusy = IsPrinting = true; Status = Resources.Strings.PrintStarted; }
private void printDocument_BeginPrint(object sender, BeginPrintEventArgs e) { // Change the current grid size to 770 fit the A4 papper size. //_gridOriginalWidth = this.Chart_Container.Width; //this.Chart_Container.Width = 775; }
private void printDocument_BeginPrint(object sender, BeginPrintEventArgs e) { // Change the current grid size to 770 fit the A4 papper size. _gridOriginalWidth = this.Chart_Grid.Width; this.Chart_Grid.Width = 770; }
private void printDocument_BeginPrint(object sender, BeginPrintEventArgs e) { }
private void printDocument_BeginPrint(object sender, BeginPrintEventArgs e) { Chart _chart = this.sp_left.Children.OfType<Chart>().FirstOrDefault(); _chart.IsEnabled = false; _spOriginalWidth = this.sp_left.Width; this.sp_left.Width = 770; }
void doc_BeginPrint(object sender, BeginPrintEventArgs e) { this.LayoutRoot.Children.Remove(img); printPanel.Children.Add(img); }
void doc_BeginPrint(object sender, BeginPrintEventArgs e) { this.Content = null; printPanel = new Grid(); printPanel.Children.Add(LayoutRoot); }
private void pdoc_BeginPrint(object sender, BeginPrintEventArgs e) { Diagram diagram = this.Diagram; if (diagram == null) return; this.EffectivePageCount = 0; // uninitialized this.PageIndex = 0; if (this.Parts != null && this.Parts.FirstOrDefault() != null) { this.PartsToPrint = new HashSet<Part>(this.Parts); } else { this.PartsToPrint = null; } diagram.Cursor = Cursors.Wait; }
private void pdoc_BeginPrint(object sender, BeginPrintEventArgs e) { Diagram diagram = this.Diagram; if (diagram == null) return; diagram.Cursor = Cursors.Wait; }
private void PrintingStartedHandler( object sender, BeginPrintEventArgs e ) { ////Now that the print page has been initialized it can just be removed from its container, ////it does not need to be readed because it only needs to initialize in the visual tree once. ////All other layout updates happen in the PrintDocument. ////NOTE:If you do not have the print page be part of the visual tree initially the first print job performed will not update correclty and therefore will not look correct. _gridContainer.Children.Clear (); //Set datacontext so bindings still function correctly _printPage.DataContext = ControlToPrint.DataContext; _parent = ControlToPrint.Parent; //Right now we are assuming the control is in a Grid, possibly change this in the furture //The control needs to be removed from the UI because it can only have one parent at any given time. ( _parent as Grid ).Children.Remove ( ControlToPrint ); _printPage.Child = ControlToPrint; _curOffset = 0.0; _totalPages = null; }
private void PdfViewerControl1_BeginPrint(object sender, BeginPrintEventArgs e) { //Insert your code here }