Section 2. methods, Closedevice method, Deviceconnect method – MagTek Excella API OCX99875557 User Manual

Page 7

Advertising
background image

3

SECTION 2. METHODS


CLOSEDEVICE METHOD
Closes the device with the given device name.


Syntax

Result =MTEXCELLAAPI1.CloseDevice (DeviceName As String) As Long

Part

Description

DeviceName

A string that specifies the name of the device to close.

Data Type

Long



DEVICECONNECT METHOD
Connects host to a device that has the given IP address or a DNS name.


Syntax

Result =MTEXCELLAAPI1.DeviceConnect (ByVal lpszDevice As String, ByVal nServerPort As
Integer, ByVal dwAccessType As Long, ByVal lpszProxyName As String, ByVal lpszProxyBypass
As String
) As Long

Part

Description

lpszDevice

A string that contains the IP address or DNS name of the device.

nServerPort

An integer that specifies the TCP/IP port on the server to which a connection is made.

dwAccessType

Type of Internet access.

This parameter can be one of the following values:

INTERNET_OPEN_TYPE_DIRECT = 1
INTERNET_OPEN_TYPE_PRECONFIG = 0
INTERNET_OPEN_TYPE_PROXY = 3
INTERNET_OPEN_TYPE_PRECONFIG_WITH_NO_AUTOPROXY = 4

lpszProxyName

A string that specifies the name of the proxy server to use when proxy access is specified by
setting dwAccessType to INTERNET_OPEN_TYPE_PROXY.

lpszProxyBypass

A string that specifies an optional list of host names or IP addresses, or both, that should not
be routed through the proxy when dwAccessType is set to
INTERNET_OPEN_TYPE_PROXY

Data Type

Long

Advertising