OCX
Modul in Visual Studio WPF |
namespace WpfBarcodeSample { public partial class MainWindow : Window { private AxBARCODELib.AxBarcode _barcode1; public MainWindow() { InitializeComponent(); _barcode1 = new AxBARCODELib.AxBarcode(); wh.Child = _barcode1; } |
_barcode1.BarcodeType = BARCODELib.enumBarcodeType.CODE_128; _barcode1.ModulBreite = BARCODELib.enumModulBreite.breite_379_µm; _barcode1.HeightMM = "20"; _barcode1.Data = this.Nutzziffer.Text; |
PrintDialog
dialog = new
PrintDialog(); if (dialog.ShowDialog() == true) { wh.Measure(new Size(dialog.PrintableAreaWidth, dialog.PrintableAreaHeight)); wh.Arrange(new Rect(0, 0, dialog.PrintableAreaWidth, dialog.PrintableAreaHeight)); wh.UpdateLayout(); dialog.PrintVisual(wh, this.data.Text); } |