ClaimedBarcodeScanner ClaimedBarcodeScanner ClaimedBarcodeScanner ClaimedBarcodeScanner ClaimedBarcodeScanner Class

Definition

Represents the claimed barcode scanner.

public : sealed class ClaimedBarcodeScanner : IClosable
struct winrt::Windows::Devices::PointOfService::ClaimedBarcodeScanner : IClosable
public sealed class ClaimedBarcodeScanner : IDisposable
Public NotInheritable Class ClaimedBarcodeScanner Implements IDisposable
// This class does not provide a public constructor.
Attributes

Windows 10 requirements

Device family
Windows 10 (introduced v10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

The object is created when ClaimScannerAsync method completes.

Version history

Windows version SDK version Value added
1703 15063 GetSymbologyAttributesAsync
1703 15063 SetSymbologyAttributesAsync
1803 17134 HideVideoPreview
1803 17134 IsVideoPreviewShownOnEnable
1803 17134 ShowVideoPreviewAsync
1809 17763 Closed

Properties

DeviceId DeviceId DeviceId DeviceId DeviceId

Gets the DeviceInformation.Id of the claimed barcode scanner.

IsDecodeDataEnabled IsDecodeDataEnabled IsDecodeDataEnabled IsDecodeDataEnabled IsDecodeDataEnabled

Gets or sets a Boolean value that indicates whether to provide the decoded data to the service object.

IsDisabledOnDataReceived IsDisabledOnDataReceived IsDisabledOnDataReceived IsDisabledOnDataReceived IsDisabledOnDataReceived

Gets or sets a Boolean value that indicates whether the barcode scanner is disabled after receiving the data.

IsEnabled IsEnabled IsEnabled IsEnabled IsEnabled

Indicates whether the barcode scanner can receive DataReceived events.

IsVideoPreviewShownOnEnable IsVideoPreviewShownOnEnable IsVideoPreviewShownOnEnable IsVideoPreviewShownOnEnable IsVideoPreviewShownOnEnable

Gets or sets whether to show the video preview window when the barcode scanner is enabled.

Methods

Close() Close() Close() Close() Close()

Releases exclusive claim to the barcode scanner. For C++ and JavaScript, use Close(). For C# and Visual Basic, use Dispose().

DisableAsync() DisableAsync() DisableAsync() DisableAsync() DisableAsync()

Puts the barcode scanner into a state where it cannot receive DataReceived events.

Dispose() Dispose() Dispose() Dispose() Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

EnableAsync() EnableAsync() EnableAsync() EnableAsync() EnableAsync()

Gets the barcode scanner into a ready state for DataReceived events.

GetSymbologyAttributesAsync(UInt32) GetSymbologyAttributesAsync(UInt32) GetSymbologyAttributesAsync(UInt32) GetSymbologyAttributesAsync(UInt32) GetSymbologyAttributesAsync(UInt32)

Gets the attributes of the specified barcode symbology.

HideVideoPreview() HideVideoPreview() HideVideoPreview() HideVideoPreview() HideVideoPreview()

Hides the video preview window.

ResetStatisticsAsync(IIterable<String>) ResetStatisticsAsync(IIterable<String>) ResetStatisticsAsync(IIterable<String>) ResetStatisticsAsync(IIterable<String>) ResetStatisticsAsync(IIterable<String>)

Resets the specified statistics to zero for all statistics that can be reset.

RetainDevice() RetainDevice() RetainDevice() RetainDevice() RetainDevice()

Retains exclusive claim to the barcode scanner.

SetActiveProfileAsync(String) SetActiveProfileAsync(String) SetActiveProfileAsync(String) SetActiveProfileAsync(String) SetActiveProfileAsync(String)

Sets the active profile on the barcode scanner.

SetActiveSymbologiesAsync(IIterable<UInt32>) SetActiveSymbologiesAsync(IIterable<UInt32>) SetActiveSymbologiesAsync(IIterable<UInt32>) SetActiveSymbologiesAsync(IIterable<UInt32>) SetActiveSymbologiesAsync(IIterable<UInt32>)

Sets the barcode symbologies for the device to use.

SetSymbologyAttributesAsync(UInt32, BarcodeSymbologyAttributes) SetSymbologyAttributesAsync(UInt32, BarcodeSymbologyAttributes) SetSymbologyAttributesAsync(UInt32, BarcodeSymbologyAttributes) SetSymbologyAttributesAsync(UInt32, BarcodeSymbologyAttributes) SetSymbologyAttributesAsync(UInt32, BarcodeSymbologyAttributes)

Sets the attributes of the barcode symbology used by the claimed barcode scanner.

ShowVideoPreviewAsync() ShowVideoPreviewAsync() ShowVideoPreviewAsync() ShowVideoPreviewAsync() ShowVideoPreviewAsync()

Shows the video preview window.

StartSoftwareTriggerAsync() StartSoftwareTriggerAsync() StartSoftwareTriggerAsync() StartSoftwareTriggerAsync() StartSoftwareTriggerAsync()

Used to signal the barcode scanner to start scanning. A session is active until StopSoftwareTriggerAsync is invoked, or until the scanner ends the session on its own.

StopSoftwareTriggerAsync() StopSoftwareTriggerAsync() StopSoftwareTriggerAsync() StopSoftwareTriggerAsync() StopSoftwareTriggerAsync()

Used to stop a session that was started with StartSoftwareTriggerAsync. No error is raised if this is called when no session is active.

UpdateStatisticsAsync(IIterable<IKeyValuePair<String, String>>) UpdateStatisticsAsync(IIterable<IKeyValuePair<String, String>>) UpdateStatisticsAsync(IIterable<IKeyValuePair<String, String>>) UpdateStatisticsAsync(IIterable<IKeyValuePair<String, String>>) UpdateStatisticsAsync(IIterable<IKeyValuePair<String, String>>)

Updates the specified statistics.

Events

Closed Closed Closed Closed Closed

Event that is raised when the ClaimedBarcodeScanner is closed.

DataReceived DataReceived DataReceived DataReceived DataReceived

Occurs when the device scans a barcode.

ErrorOccurred ErrorOccurred ErrorOccurred ErrorOccurred ErrorOccurred

Occurs when there is a problem in reading a barcode.

ImagePreviewReceived ImagePreviewReceived ImagePreviewReceived ImagePreviewReceived ImagePreviewReceived

Occurs when the device receives the bitmap image of the scan.

ReleaseDeviceRequested ReleaseDeviceRequested ReleaseDeviceRequested ReleaseDeviceRequested ReleaseDeviceRequested

Occurs when the device gets a request to release its exclusive claim.

TriggerPressed TriggerPressed TriggerPressed TriggerPressed TriggerPressed

Occurs when the barcode scanner trigger or button is pressed during a scanning operation.

TriggerReleased TriggerReleased TriggerReleased TriggerReleased TriggerReleased

Occurs when the barcode scanner trigger or button is released during a scanning operation.

See also