Mprintstatus method, Openport method, Openport method 2 – MagTek BLUETOOTH SWIPE READER User Manual

Page 17: Mprintstatus, Method, Openport

Advertising
background image

Methods

11

MPRINTSTATUS METHOD

Returns an integer value indicating the status of MagnePrint data.

Syntax
int MPrintStatust()

OPENPORT METHOD

Returns an integer value indicating the status of the OpenPort method. This OpenPort(port)
function provides a short-cut to connect to a Magtek Bluetooth card reader using default settings:
baud rate of 9600, parity of ‘N’, data bits of 8, and stop bits of 1.

Syntax
int OpenPort(String port)

Remarks
Returns zero (0) if the port can be open, otherwise a non-zero for error.

The OpenPort method syntax has this part:





Example
String portName = “COM7”;
int stat = OpenPort(portName);
This returns a zero (0) if the port can be open.

OPENPORT METHOD 2

Returns an integer value indicating the status of the OpenPort method.

Syntax
int OpenPort(String sPortname, String sBaudRate, String sDataBits, String sStopBits, String
sParityType
)

Remarks
Returns a zero (0) if the port can be open, otherwise a non-zero for error.

Part

Data Type

Description

portName

String

Name of a port to open such as COM1, COM7

Advertising