Exemplo n.º 1
0
        private void button_start_api_Click(object sender, RoutedEventArgs e)
        {
            RegisterCallBack();
            ZOOM_SDK_DOTNET_WRAP.StartParam param = new ZOOM_SDK_DOTNET_WRAP.StartParam();
            param.userType = ZOOM_SDK_DOTNET_WRAP.SDKUserType.SDK_UT_APIUSER;
            ZOOM_SDK_DOTNET_WRAP.StartParam4APIUser start_api_param = new ZOOM_SDK_DOTNET_WRAP.StartParam4APIUser();
            start_api_param.meetingNumber = UInt64.Parse(textBox_meetingnumber_api.Text);
            start_api_param.userID        = textBox_userid_api.Text;
            start_api_param.userToken     = textBox_usertoken_api.Text;
            start_api_param.userName      = textBox_username_api.Text;
            param.apiuserStart            = start_api_param;

            ZOOM_SDK_DOTNET_WRAP.SDKError err = ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().Start(param);
            if (ZOOM_SDK_DOTNET_WRAP.SDKError.SDKERR_SUCCESS == err)
            {
                Hide();
            }
            else//error handle
            {
            }
        }
        private void button_start_api_Click(object sender, RoutedEventArgs e)
        {
            RegisterCallBack();
            ZOOM_SDK_DOTNET_WRAP.StartParam param = new ZOOM_SDK_DOTNET_WRAP.StartParam();
            param.userType = ZOOM_SDK_DOTNET_WRAP.SDKUserType.SDK_UT_WITHOUT_LOGIN;
            ZOOM_SDK_DOTNET_WRAP.StartParam4WithoutLogin start_withoutlogin_param = new ZOOM_SDK_DOTNET_WRAP.StartParam4WithoutLogin();
            start_withoutlogin_param.meetingNumber = UInt64.Parse(textBox_meetingnumber_api.Text);
            start_withoutlogin_param.userID        = textBox_userid_api.Text;
            start_withoutlogin_param.userZAK       = textBox_AccessToken.Text;
            start_withoutlogin_param.userName      = "******";
            start_withoutlogin_param.zoomuserType  = ZOOM_SDK_DOTNET_WRAP.ZoomUserType.ZoomUserType_APIUSER;
            param.withoutloginStart = start_withoutlogin_param;

            ZOOM_SDK_DOTNET_WRAP.SDKError err = ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().Start(param);
            if (ZOOM_SDK_DOTNET_WRAP.SDKError.SDKERR_SUCCESS == err)
            {
                Hide();
            }
            else//error handle
            {
            }
        }
Exemplo n.º 3
0
        private void button_start_api_Click(object sender, RoutedEventArgs e)
        {
            ZOOM_SDK_DOTNET_WRAP.StartParam param = new ZOOM_SDK_DOTNET_WRAP.StartParam();
            param.userType = ZOOM_SDK_DOTNET_WRAP.SDKUserType.SDK_UT_NORMALUSER;
            ZOOM_SDK_DOTNET_WRAP.StartParam4NormalUser start_normal_param = new ZOOM_SDK_DOTNET_WRAP.StartParam4NormalUser();

            if (settings.Participants.Count > 1)
            {
                this.userName = $"{textBox_DisplayName.Text} x {settings.Participants.Count}";
            }
            else
            {
                this.userName = $"{textBox_DisplayName.Text}";
            }

            start_normal_param.meetingNumber        = UInt64.Parse(textBox_meetingnumber_api.Text.Replace("-", "").Replace(" ", ""));
            start_normal_param.participantId        = this.userName;
            start_normal_param.isAudioOff           = false;
            start_normal_param.isVideoOff           = true;
            start_normal_param.isDirectShareDesktop = false;

            param.normaluserStart = start_normal_param;


            ZOOM_SDK_DOTNET_WRAP.SDKError err = ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().Start(param);

            if (SDKError.SDKERR_SUCCESS == err)
            {
                feedback.Content = $"Starting Meeting {textBox_meetingnumber_api.Text}: {err}";
                Hide();
            }
            else//error handle
            {
                feedback.Content = $"Failed to start meeting {textBox_meetingnumber_api.Text}: {err}";
                Console.WriteLine(err);
            }
        }