Пример #1
0
        async void OnConnectServer(object obj)
        {
            var result = await ConnectService.ConnectAsync(IpString, 8181);

            string strResult = result == true ? "连接成功!" : "连接失败";
            await DialogService.ShowAlertAsync(strResult, "连接PC服务器结果", "知道了");
        }
Пример #2
0
        async void ConnectServer()
        {
            if (ConnectService.SendMessage("ok") == true)
            {
                return;
            }
            var result = await ConnectService.ConnectAsync("192.168.223.195", 8181);

            if (result == true)
            {
                await DialogService.ShowAlertAsync("连接服务器成功!");
            }
        }