Joining a Meeting
JoinConfById
API Description
This API is used to join an existing meeting by using the meeting ID and password.
Precautions
- This API can be called regardless of whether you have logged in.
- This API is an asynchronous API. The return value only indicates whether the API is successfully called. The actual service processing result is returned in the corresponding callback function.
Method Definition
1
|
HWM_SDK_AGENT_API hwmsdk::HwmErrCode JoinConfById(HwmJoinConfByIdInfo *joinConfByIdInfo); |
Callback Function
1
|
virtual void OnJoinConfByIdResult(hwmsdk::HwmErrCode ret, const char* reason) {}; |
Parameter Description
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
confId |
Yes |
char[] |
Meeting ID. |
password |
No |
char[] |
Meeting password. To join a meeting as a host, pass the host password. To join a meeting as a guest, pass the guest password or leave it empty if the meeting is password-free. |
name |
No |
char[] |
Display name in the meeting. If you have logged in, this parameter can be left blank. In such a case, the login username is used as the display name in the meeting. To join a meeting anonymously, you must enter this name or set the participant name in advance. |
isCloseSpk |
No |
bool |
Whether to disable the speaker. Enter true to disable the speaker or false to enable it. |
isStopConflictConf |
No |
bool |
Used to forcibly end a meeting that conflicts with the current cloud meeting room. (Only the owner of the cloud meeting room resource has the permission.) |
Return Values
Type |
Description |
---|---|
HwmErrCode |
If 0 is returned, the operation is successful. If other values are returned, the operation fails. For details about values returned upon failures, see Common Error Codes. |
Sample Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
// Join a meeting using the meeting ID. int demoJoinConfByIdDlg::clickJoinConfById() { // Enter the meeting ID and meeting password. You can specify your display name in the meeting regardless of whether you have logged in or not. hwmsdkagent::HwmJoinConfByIdInfo data; memset(&data, 0, sizeof(hwmsdkagent::HwmJoinConfByIdInfo)); strncpy_s(data.confId, GetMeetingID().c_str(), HWM_MAX_CONF_ID_LEN); strncpy_s(data.password, GetAccessCode().c_str(), HWM_MAX_PASSWORD_LEN); strncpy_s(data.name, GetParticipantName().c_str(), HWM_MAX_DISPLAY_NAME_LEN); data.isCloseSpk = false; // Enable or disable the microphone and camera. int ret = EnableFeature(hwmsdkagent::HWM_ENABLE_FEATURE_TYPE_MIC_SWITCH, true); ret = EnableFeature(hwmsdkagent::HWM_ENABLE_FEATURE_TYPE_CAM_SWITCH, false); ret = hwmsdkagent::JoinConfById(&data); return ret; } |
Before joining a meeting, you can call EnableFeature to change the microphone and camera status.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot