Open participant and chat like popup window instead of a panel inside zoom container

Hi, i´m using the C# wrapper
I am looking the way for open te participant list and chat in a separate window. I run the same app in diferent computers obtaining different results. Pop up window in desktop PC and inside Zoom panel in a notebook. How to manage this?
I tryed redirecting event with:
ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetUIController().Add_CB_onParticipantListBtnClicked(onParticipantListBtnClicked);
but this block completely inabilite the list to open.
Thanks in advance, sorry for the english

Using windows sdk v5.2.41727.0928

1 Like

Hi @fpujol,

Thanks for the post and pardon the late response. You may use the ShowParticipantListWnd and ShowChatDlg to get the handle of the participant window and the chat window, then you could use this handle to achieve what you are trying to do.

Hope this helps. Thank you.

@Carson_Chen And @Michael_Condon

So I’m trying to get the chatDialog window handle but It’s been proving a bit difficult. I have been doing it in the following manner after the meeting window has opened successfully
I’m doing it in the following manner

IMeetingUIControllerDotNetWrap uictrl_service = CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetUIController();
    ShowChatDlgParam firstHwd = new ShowChatDlgParam();
    ValueType va_1 = firstHwd; 

    uictrl_service.ShowChatDlg(ref va_1);
    ShowChatDlgParam chat_exposed = (ShowChatDlgParam)va_1;

the Code below is causing problems because of the casting of a null

HWNDDotNet temp = (HWNDDotNet)chat_exposed.hChatWnd;
Console.WriteLine("Chat window handle " + temp.value);

The output I get before the crash is the following

Object reference not set to an instance of an object.

I’m trying to follow the findings from this post

The Question

How do I get the handle of the Chat window?

Hey @ekaram,

Sorry for the delay in response here. I spiraled down the rabbit hole on this one and found something interesting. If you open up the file meeting_ui_ctrl_warp.h in the wrapper project itself, there is a line of code:
DEFINE_FUNC_1(ShowChatDlg, SDKError, ShowChatDlgParam&, param)
This line is supposed to convert the ShowChatDlg function in the c++ sdk, to a C# function.
However, if you ctrl+click on ShowChatDlg it does not take you to the ShowChatDlg function, but instead takes you to ShowChatDlgParam.
This means the wrapper is confusing the C++ ShowChatDlgParam struct with the C++ ShowChatDlg function.
Similarly, I noticed that this same issue happens with ShowSettingDlg and ShowSettingDlgParam. So my suspicion is that the wrapper gets confused when it is trying to wrap a function that has a name similar to the function. I am not yet sure why this is happening, but I have an idea for a possible workaround for this issue.

Can you try something:

  1. In the wrapper project itself, change the name ShowChatDlgParam to “ChatDialogueWindowParam” (or any name that is not similar to ShowChatDlg)
  2. Update all references to ShowChatDlgParam (if you build, Visual Studio will create errors for all the spots that need to be updated)
  3. Then rebuild the wrapper
  4. Update your app with the modified version of the wrapper and try running again.

I am curious if the reason you are facing issues here is because the wrapper is confusing names.

Thanks!
Michael

So that’s odd. I changed the name and it still points to that function on the control-click.

In addition, the error is still the same when I run it. (code is pasted below)

IMeetingUIControllerDotNetWrap uictrl_service = CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetUIController();`
ChatDialogueWindowParam firstHwd = new ChatDialogueWindowParam();
ValueType va_1 = firstHwd;
uictrl_service.ShowChatDlg(ref va_1);
ChatDialogueWindowParam chat_exposed = (ChatDialogueWindowParam)va_1;

HWNDDotNet temp = (HWNDDotNet)chat_exposed.hChatWnd;
Console.WriteLine("Chat window handle " + temp.value);

Now it would be good to note that Visual Code points to the right function on ctrl-click before the function rename. (right click go to definition)

Hey @ekaram,

Hmm, I see. That is disappointing. I have the engineers investigating this now. Hopefully we can find the root cause and a workaround.

Thanks!
Michael

1 Like

Hey @ekaram,

Can you try this code?

IMeetingUIControllerDotNetWrap uictrl_service = CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetUIController();
ShowChatDlgParam chat_dlg_param= new ShowChatDlgParam();
HWNDDotNet chat_wnd_handle = new HWNDDotNet(); //new code
chat_dlg_param.hChatWnd = chat_wnd_handle; //new code
ValueType va_1 = chat_dlg_param;
uictrl_service.ShowChatDlg(ref va_1);

ShowChatDlgParam chat_exposed = (ShowChatDlgParam)va_1;
HWNDDotNet temp_wnd = (HWNDDotNet)chat_exposed.hChatWnd; //new code
UInt32 temp_wnd_int = (UInt32)temp_wnd.value;
Console.WriteLine("Chat window handle ");
Console.WriteLine(temp_wnd_int);

Thanks!
Michael

Hey Michael,

I still get null with that code when I print the handle. The chat dialog pops up the handle value is null

Chat window handle 
0