TX Text Control .NET Server

BarcodeFrame Class

Class|Introduced in 19.0
Namespace
TXTextControl.DataVisualization
Package
TXTextControl.TextControl.Core.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.Core.dll
Install
dotnet add package TXTextControl.TextControl.Core.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.dll from the setup.
Also in
TXTextControl.TextControl.ASP.SDK as TXTextControl.dll
Inherits
  1. FrameBase
  2. BarcodeFrame

Description

An instance of the BarcodeFrame class represents a barcode and its layout in a Text Control document. A barcode can be positioned in the document like an image or a textframe, either geometrically or as a single character. Geometrically its position can either be relative to a paragraph to which it is anchored or relative to the complete document. The BarcodeFrame class handles the positioning of the barcode in the document. A barcode frame is always associated with a barcode control of the type TXTextControl.Barcode.TXBarcodeControl or TXTextControl.WPF.Barcode.TXBarcodeControl. This barcode control handles the appearance and the data of the barcode. All barcodes in a document are contained in a BarcodeCollection. The collection can also be used to add barcodes to or to remove barcodes from the document. The barcode collection can be obtained through the TextControl.Barcodes, WPF.TextControl.Barcodes or ServerTextControl.Barcodes property.

Syntax

public class BarcodeFrame : FrameBase

Examples

The following example creates a Barcode Frame instance and configures its export compression quality setting for a document workflow.

TXTextControl.DataVisualization.BarcodeFrame barcodeFrame = new("Approved");
barcodeFrame.ExportCompressionQuality = 90;

Members

Constructors

ConstructorDescription
BarcodeFrameInitializes a new instance of the BarcodeFrame class.

Properties

PropertyDescription
AlignmentGets or sets the frame's horizontal alignment when it is anchored to a paragraph. (Inherited from FrameBase.)
BarcodeGets the barcode control associated with the barcode frame. It must be of the type TXTextControl.Barcode.TXBarcodeControl or TXTextControl.WPF.Barcode.TXBarcodeControl.
BoundsGets the frame's bounding rectangle relative to the upper left corner of the document. (Inherited from FrameBase.)
DescriptiveTextGets or sets a descriptive text for the frame. An empty string indicates that the frame has no such text. An empty string can also be used to delete a previously set text. (Inherited from FrameBase.)
ExportCompressionQualitySets a value between 1 and 100, which is the quality of a lossy data compression used, if the barcode's image is exported. It is only used, if the image data is compressed with a lossy compression algorithm. A value of 100 indicates the maximum quality, a value of 1 indicates the minimum quality. If this property is set to zero, which is the default value, Text Control uses the quality value set with the SaveSettings.ImageCompressionQuality property.
ExportFileNameGets or sets the file name, when the barcode's image is exported. An empty string indicates that no export filename has currently be specified for the barcode's image. In this case a constructed filename is used. A filename is constructed in the following form: <document_filename>_<number>.<extension>. The technical article Loading and Saving Images describes where newly created image files are stored.
ExportFilterIndexGets or sets the format used, if a barcode's image is exported. This is the number of the filter in the string returned through the ImageCollection.ExportFilters property, beginning with number one. A value of zero indicates that no export format has currently be specified for the barcode. In this case the barcode's image is saved in Windows Bitmap format. The technical article Loading and Saving Images lists the currently possible values for this property.
ExportResolutionGets or sets the maximum resolution in dots per inch in which the barcode's image is saved. If this property's value is zero, which is the default value, Text Control uses the resolution value set with the SaveSettings.ImageMaxResolution property.
IDGets or sets an identifier for the frame. It must be a one-based value. A value of zero indicates that the image, text frame, chart, barcode or drawing has no identifier. Zero can also be used to delete a previously set identifier. (Inherited from FrameBase.)
InsertionModeGets or sets a value determining whether the frame is treated as a single character or the document's text either flows around or overwrites the frame. If the document's text flows around or overwrites the frame, this property also determines whether the image, text frame, chart, barcode or drawing is moved with the text or fixed positioned on a page. (Inherited from FrameBase.)
LocationGets or sets, in twips, the frame's current location. If the image, text frame, chart, barcode or drawing is anchored to a paragraph, the location is relative to the paragraph. Otherwise, it is relative to the document. If the frame has a horizontal alignment or if it is inserted inline, this property returns zero. This property cannot be set for images, text frames, charts, barcodes or drawings which are inserted inline. (Inherited from FrameBase.)
MoveableDetermines whether a frame can be moved in the document at run time with the built-in mouse interface. (Inherited from FrameBase.)
NameGets or sets a name for the frame. An empty string indicates that the frame has no name. An empty string can also be used to delete a previously set name. (Inherited from FrameBase.)
SaveModeDetermines whether the barcode's image is stored through its binary data or through a file reference. By default a barcode's image is stored with its binary data.
SizeGets or sets the frame's size in twips. For images this property is read only. (Inherited from FrameBase.)
SizeableDetermines whether the frame can be resized at run time with the built-in mouse interface. (Inherited from FrameBase.)
TextDistancesGets or sets the distances, in twips, between the frame and the document's text. The property's value is an array of four variables specifying the distances in the following order: left, top, right and bottom. If a value is set to -1, it is not changed. (Inherited from FrameBase.)
TextPositionRead only. Gets the frame's character position in the document's text (one-based). (Inherited from FrameBase.)

Methods

MethodDescription
AddUndoUnitAdds the current state of the barcode which is connected with this BarcodeFrame to the undo stack. Programmatic changes performed with the barcode's properties and methods are not automatically added to a TextControl's undo stack. Calling this method is not necessary, when the barcode frame's layout in the text is changed.
ChangeZOrderChanges the frame's z-order. (Inherited from FrameBase.)
RefreshRefreshes the barcode. Programmatic changes performed with the barcode's properties and methods are not automatically refreshed. Calling this method is not necessary, when the barcode frame's layout in the text is changed.