ConfigurePort

機能
ポート設定用ダイアログボックスを表示する
Declare Function ConfigurePort Lib "winspool.drv" Alias "ConfigurePortA" _
(ByVal pName As String, ByVal hWnd As Long, ByVal pPortName As String) As Long
Declare Function ConfigurePort Lib "winspool.drv" Alias "ConfigurePortA" _
(ByVal pName As String, ByVal hWnd As Integer, ByVal pPortName As String) As Integer

BOOL ConfigurePort(
LPTSTR pName,
HWND hWnd,
LPTSTR pPortName
);
引数
pName

サーバー名(ローカルプリンタのときvbNullString)
hWnd
ダイアログの親ウィンドウのハンドル
pPortName
ポート名
戻り値
正常終了のとき       0以外
中止のとき           0
備考
有効なポート名はEnumPorts()関数を使って調べる