PageSettings properties in .NET

Printer Code128 in .NET PageSettings properties
Table 1110 PageSettings properties
Code 128 Code Set C Generation In .NET Framework
Using Barcode drawer for Visual Studio .NET Control to generate, create Code 128A image in .NET framework applications.
Property Bounds Color Returns the size of the page Indicates whether the page should be printed in color Both get and set The default is determined by the printer Description
ANSI/AIM Code 128 Recognizer In .NET
Using Barcode scanner for Visual Studio .NET Control to read, scan read, scan image in .NET framework applications.
This document was created by an unregistered ChmMagic, please go to http://wwwbisentercom to register it Thanks
Bar Code Encoder In .NET
Using Barcode creation for .NET framework Control to generate, create barcode image in Visual Studio .NET applications.
Property Landscape
Scanning Barcode In .NET
Using Barcode reader for VS .NET Control to read, scan read, scan image in .NET applications.
Description Indicates whether the page is printed in landscape or portrait orientation Both get and set The default is determined by the printer Identifies the page margins Both get and set Identifies the paper size Both get and set Identifies the paper source (a printer tray) Both get and set
Generate Code 128 Code Set A In C#.NET
Using Barcode maker for .NET Control to generate, create Code 128 Code Set B image in .NET framework applications.
Margins PaperSize PaperSource
Code 128A Creator In Visual Studio .NET
Using Barcode encoder for ASP.NET Control to generate, create Code 128 image in ASP.NET applications.
PrinterResolution Identifies the printer resolution for the page Both get and set PrinterSettings Identifies the printer settings associated with the page Both get and set
Code-128 Printer In Visual Basic .NET
Using Barcode drawer for .NET Control to generate, create Code128 image in .NET framework applications.
1193 Creating a Custom Paper Size
Make EAN 13 In Visual Studio .NET
Using Barcode generation for .NET framework Control to generate, create EAN / UCC - 13 image in VS .NET applications.
As mentioned earlier, the PaperSize class specifies the size and type of paper You can create your own custom paper sizes For example, Listing 1137 creates a custom paper size with a height of 200 and a width of 100
Universal Product Code Version A Drawer In .NET Framework
Using Barcode maker for Visual Studio .NET Control to generate, create UPC-A Supplement 2 image in VS .NET applications.
Listing 1137 Creating a custom paper size
Data Matrix Maker In VS .NET
Using Barcode generation for VS .NET Control to generate, create ECC200 image in Visual Studio .NET applications.
// Create a custom paper size and add it to the list PaperSize customPaperSize = new PaperSize(); customPaperSizePaperName = "Custom Size"; customPaperSizeHeight = 200; customPaperSizeWidth = 100;
Draw Barcode In VS .NET
Using Barcode creator for .NET Control to generate, create barcode image in .NET applications.
1194 The PaperKind Enumeration
Creating USPS POSTal Numeric Encoding Technique Barcode In .NET Framework
Using Barcode printer for VS .NET Control to generate, create USPS POSTal Numeric Encoding Technique Barcode image in VS .NET applications.
The PaperKind enumeration, as we saw earlier, is used by the Kind property to specify standard paper sizes This enumeration has over 100 members Among them are A2, A3, A3Extra, A3ExtraTransverse, A3Rotated, A3Transverse, A4, A5, A6, Custom, DCEnvelope, Executive, InviteEnvelope, ItalyEnvelope, JapanesePostcard, Ledger, Legal, LegalExtra, Letter, LetterExtra, LetterSmall, Standard10x11 (10x14, 10x17, 12x11, 15x11, 9x11), Statement, and Tabloid
ANSI/AIM Code 128 Recognizer In .NET Framework
Using Barcode recognizer for Visual Studio .NET Control to read, scan read, scan image in Visual Studio .NET applications.
1195 The PaperSourceKind Enumeration
Recognizing Data Matrix In VS .NET
Using Barcode reader for .NET Control to read, scan read, scan image in .NET framework applications.
The PaperSourceKind enumeration represents standard paper sourcesTable 1111 describes the members of the PaperSourceKind enumeration
EAN-13 Supplement 5 Decoder In .NET
Using Barcode reader for Visual Studio .NET Control to read, scan read, scan image in .NET framework applications.
This document was created by an unregistered ChmMagic, please go to http://wwwbisentercom to register it Thanks
Code 39 Scanner In Visual Studio .NET
Using Barcode decoder for .NET Control to read, scan read, scan image in VS .NET applications.
Table 1111 PaperSourceKind members
Bar Code Generator In Visual Basic .NET
Using Barcode encoder for VS .NET Control to generate, create barcode image in .NET framework applications.
Member AutomaticFeed Cassette Custom Envelope FormSource LargeCapacity LargeFormat Lower Manual ManualFeed Middle SmallFormat TractorFeed Upper Automatically fed paper A paper cassette A printer-specific paper source An envelope The printer's default input bin The printer's large-capacity bin Large-format paper The lower bin of a printer Manually fed paper Manually fed envelope The middle bin of a printer Small-format paper A tractor feed The upper bin of a printer Description
Create Code 128 In Java
Using Barcode drawer for Java Control to generate, create Code128 image in Java applications.
1196 Page Settings in Action
USS Code 39 Creator In Visual C#.NET
Using Barcode generation for Visual Studio .NET Control to generate, create Code 39 image in Visual Studio .NET applications.
Now let's create an application that will allow us to get and set page settings In this application we will create a custom dialog We start by creating a new Windows application in VSNET We add some controls to the form, with the result shown in Figure 1122 The Available Printers combo box displays all available printers The Size and Source combo boxes display paper sizes and sources, respectively The Paper Orientation section indicates whether paper is oriented in landscape mode or portrait mode The Paper Margins text boxes obviously represent left, right, top, and bottom margins The Bounds property is represented by the Bounds (Rectangle) text box The Color Printing check box indicates whether the printer supports color printing TheSet Properties button allows us to enter new values in the controls
Bar Code Maker In .NET Framework
Using Barcode creation for ASP.NET Control to generate, create barcode image in ASP.NET applications.
Figure 1122 The custom page settings dialog
This document was created by an unregistered ChmMagic, please go to http://wwwbisentercom to register it Thanks
The form's load event (see Listing 1138), loads all the required PageSettings-related settings using the LoadPrinters, LoadPaperSizes, LoadPaperSources, and ReadOtherSettings methods
Listing 1138 The form's load event handler
private void Form1_Load(object sender, SystemEventArgs e) { // Load all available printers LoadPrinters(); // Load paper sizes LoadPaperSizes(); // Load paper sources LoadPaperSources(); // Load other settings ReadOtherSettings(); } The LoadPrinters, LoadPaperSizes, LoadPaperSources, and ReadOtherSettings methods are used to load printers, paper sizes, paper sources, and other properties, respectively The LoadPrinters method is given in Listing 1139 We simply read the InstalledPrinters property of PrinterSettings and add printers to the printersList combo box
Listing 1139 Loading printers
private void LoadPrinters() { // Load all available printers foreach(String printer in PrinterSettingsInstalledPrinters) { printersListItemsAdd(printerToString()); } printersListSelect(0, 1); }
This document was created by an unregistered ChmMagic, please go to http://wwwbisentercom to register it Thanks
The LoadPaperSizes method (see Listing 1140), loads all available paper sizes to the combo box We read the PaperSizes property of PrinterSettings and add the paper type to the combo box Then we create a custom paper size and add this to the combo box as well This example will give you an idea of how to create your own custom paper sizes