Jazz Soft 您要聯絡嗎?   JazzSoft@live.com     繁體字漢語   英語  日語  繁體字漢語  簡體字漢語
提供半導體工廠自動化與生産效率改善法 
Skip Navigation Links首頁 > 產品一覽 > Savoy > Savoy HSMS 詳細資料 > Properties > Connect

Dorian.Core is added. Dorian now supports .NET 6 and 7.

Savoy HSMS 詳細資料   

Properties
Appearance
BorderStyle
Connect
IniFileName
IniSection
IPAddress
Log
LogBakCount
LogFileName
LogSize
LogVerbose
MyHostName
MyPortNumber
PortNumber
Selected
Server
T3
T5
T6
T7
T8

Methods
AboutBox
Disconnect
LoadIniFile
Send
Setup
ToIPAddress

Events
Connected
Disconnected
Problem
Received
SelChanged

Connect Property

Gets or sets the HSMS connection status. If Connect property is set to true where Server property is false (client), SavoyHsms control will attempt to establish connection. If connection has not been established, Connect property will be set to false.

If Connect property is set to true where Server property is true (server), SavoyHsms control will attempt to open server port and start listening to prepare for future incoming connection. At this time connection has not been established until client connected server. Therefore, even no connection was made, Connect property would be True, when server port was opened.

If user sets False to Connect property, existing connection will be disconnected. User doesn’t have to worry about connection to make sure it is disconnected when application is closing. SavoyHsms control will take care disconnection automatically. When Server property was set to True and Connected property is set to False, all existing connections with clients will be disconnected.

Syntax

Visual Basic

Connect As Boolean


Visual C++

BOOL GetConnect()
void SetConnect(BOOL)

Return Value

Example

Visual Basic

.IPAddress = "hsms_server"
.PortNumber = 5000
.MyPortNumber = 0
.Server = False
.Connect = True ' Open
If Not .Connect then
  MsgBox "Cannot connect to server!"
End If


Visual C++

m_ctrl.SetIPAddress("hsms_server");
m_ctrl.SetPortNumber(5000);
m_ctrl.SetLocalPortNumber(0);
m_ctrl.SetServer(false);
m_ctrl.SetConnect(true); // Open
if(!m_ctrl.GetConnect())
  MessageBox("Cannot connect to server!");

Remarks

If Connect property on server side was set to False, connection would be disconnected. Therefore, Connect property on client side would also be set to False.

See Also

您要聯絡嗎?   JazzSoft@live.com
  Copyright © 1997 - 2024 Jazz Soft, Inc.