웹소켓서버 » Event

on_open

Description

세션 연결시 이벤트

Parameters

Parameters Type Description
objInst INSTANCE 컴포넌트 인스턴스
strRemoteIP STRING 원격지 IP
nRemotePort short 원격지 포트
strSocketKey STRING 원격지 소켓 키

Return Value

Type Description
void

Example

function wssvr01_on_open(objInst, strRemoteIP, nRemotePort, strSocketKey)
{
	// 세션 연결
	var nRow;
	
	factory.consoleprint("OnConnect> strRemoteIP = " + strRemoteIP);
	factory.consoleprint("OnConnect> nRemotePort = " + nRemotePort);
	factory.consoleprint("OnConnect> strSocketKey = " + strSocketKey);	
		
	nRow = grdSessionList.additem();
	grdSessionList.setitemtext(nRow, 0, strRemoteIP);
	grdSessionList.setitemtext(nRow, 1, nRemotePort);
	grdSessionList.setitemtext(nRow, 2, strSocketKey);
}

Viewer Ver.

9.1.1.1

Update Date

20231103