# ZoomSDKError 4 on UI functions

**URL:** <https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576>\
**Category:** macOS\
**Created:** [December 16, 2020, 7:37pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576 "2020-12-16T19:37:46Z")\
**Posts on this page:** 18\
**Page:** 2

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 12, 2021, 11:02pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/21 "2021-01-12T23:02:23Z")

</div>

Hey @tmiskiew,

Jon is currently out, so I will be taking over this thread until he returns.

Within ZoomSDKMeetingUIController, there are various interfaces that may be useful to you. You can use getWallViewPageInfo to get page info of the wall view, and showPreOrNextPageWallView to navigate through it.

> [@tmiskiew](#):
>
> How we can find out the (initial) state of these buttons?

Unfortunately there are not callbacks to alert of these buttons being pressed or the current state. However, you can control these programmatically with these functions in ZoomSDKMeetingUIController

- (ZoomSDKError)switchFloatVideoToMinimizeMode;
- ZoomSDKError)switchFloatVideoToWallMode;
- (ZoomSDKError)switchFloatVideoToActiveSpeakerMode;
- (ZoomSDKError)switchFloatVideoToGalleryMode;

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 12, 2021, 11:14pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/22 "2021-01-12T23:14:01Z")

</div>

Hey @j_a_z_z,

> [@j\_a\_z\_z](#):
>
> - Callback when the left floating panel with buttons 1,2,3, 4 appears. May be a delegate in SDK which I can listen to. I want to show the buttons in the app, only when they are visible in Zoom UI.
> - Callback when Zoom UI full screen state changes, I figured that when a user is already sharing the screen and I join that meeting, zoom app automatically move me to full screen which results in incorrect button state ☹

Unfortunately, there are not currently interfaces for this.

> [@j\_a\_z\_z](#):
>
> I am getting this as false for my user, will this property value change when somebody started a screen share and button 4 is visible in zoom UI?

This is only possible if the user is sharing.

To be alerted that someone started sharing you can use [onSharingStatus:User:](https://marketplacefront.zoom.us/sdk/meeting/macos/protocol_zoom_s_d_k_a_s_controller_delegate_01-p.html#ad4d13d7ca248098d4e5ec340704eb7bc)

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![tmiskiew](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tmiskiew/32/9174_2.png) [@tmiskiew](https://devforum.zoom.us/u/tmiskiew)\
**Post date:** [January 13, 2021, 5:09am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/23 "2021-01-13T05:09:46Z")

</div>

@Michael_Condon showPreOrNextPageWallView is not working. It’s for the gallery view only.

 ![image](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/9/3/93cd052014c07af8f324d7681b044aed74d95850.jpeg)

This is NOT the same as the one I asked for. May I ask you to check with engineering (feel free to use the screenshots I provided)? Shall the interfaces be still not available may you please create a feature request for us?

With regards to those switchFloat\* buttons I can control them, yes. But I want to show the correct current state to the user and without a call like that I can’t. Can you add it by any chance?

---

<div class="post-metadata">

**Author:** ![j\_a\_z\_z](https://avatars.discourse-cdn.com/v4/letter/j/439d5e/32.png) [@j\_a\_z\_z](https://devforum.zoom.us/u/j_a_z_z)\
**Post date:** [January 13, 2021, 4:57pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/24 "2021-01-13T16:57:05Z")

</div>

Hey @Michael_Condon  
Thanks for your response, Can you please share the code on how can I assign my object to this delegate.

I tried using below code to get the user ids, who are sharing screen, but the ids it returns are different and they are not matching participatnt IDs.

```auto
self.sdk.getMeetingService()?.getASController()?.getShareSourceList()

```

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 14, 2021, 8:55pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/25 "2021-01-14T20:55:40Z")

</div>

@tmiskiew,

My apologies, it looks like I misinterpreted what that feature did. I will submit feature requests for both of these (if we do not already have them).

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 14, 2021, 9:07pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/26 "2021-01-14T21:07:17Z")

</div>

Hey @j_a_z_z,

To get the userID’s of the users who are actively sharing, you can call - [getShareSourceList](https://marketplacefront.zoom.us/sdk/meeting/macos/interface_zoom_s_d_k_a_s_controller.html#a0af630b5112df43e1d5a9978788370d4) from the ZoomSDKASController.

To be alerted that someone started sharing you can use - [onSharingStatus:User:](https://marketplacefront.zoom.us/sdk/meeting/macos/protocol_zoom_s_d_k_a_s_controller_delegate_01-p.html#ad4d13d7ca248098d4e5ec340704eb7bc)

To assign your object as a delegate you would call:

> ZoomSDKMeetingService\* meetingService = [[ZoomSDK sharedSDK] getMeetingService];  
> if(meetingService)  
> {  
> let shareController = [meetingService getASController];  
> shareController.delegate = self;  
> }

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![j\_a\_z\_z](https://avatars.discourse-cdn.com/v4/letter/j/439d5e/32.png) [@j\_a\_z\_z](https://devforum.zoom.us/u/j_a_z_z)\
**Post date:** [January 15, 2021, 11:45am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/27 "2021-01-15T11:45:14Z")

</div>

Hey @Michael_Condon

Thanks for your response, The documentation references you shared are not for Mac OS SDK.  
Can you please update them.

Also, Please review these two posts from me, they are related to same topic.

- [ZoomSDKASControllerDelegate is not called in latest Mac OS SDK update](https://devforum.zoom.us/t/zoomsdkascontrollerdelegate-is-not-called-in-latest-mac-os-sdk-update/40485)
- [swapToShowShareViewOrVideo is not working as intended](https://devforum.zoom.us/t/swaptoshowsharevieworvideo-is-not-working-as-intended/40479)

---

<div class="post-metadata">

**Author:** ![jon.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/jon.zoom/32/13495_2.png) [@jon.zoom](https://devforum.zoom.us/u/jon.zoom)\
**Post date:** [January 20, 2021, 1:29am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/28 "2021-01-20T01:29:11Z")

</div>

Hi @tmiskiew and @j_a_z_z,

Apologies for the mixup in platforms earlier! I can assure you that Michael has properly submitted the feature request for macOS and not Android as the links suggest. 🙂

I will be sure to give you an update once we have more information! Also, since there is a lot of information in this thread nowadays, please let me know if there is any additional action needed that I may have overlooked (other than the two feature requests Michael submitted last week).

Thanks!

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 20, 2021, 6:18pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/29 "2021-01-20T18:18:58Z")

</div>

Hey @j_a_z_z,

I apologize for my mixup in platform documentation links. I have since updated those links. Please let us know if you have any other questions there.

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![tmiskiew](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tmiskiew/32/9174_2.png) [@tmiskiew](https://devforum.zoom.us/u/tmiskiew)\
**Post date:** [January 20, 2021, 9:39pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/30 "2021-01-20T21:39:21Z")

</div>

@Michael_Condon which links did you update? When I click on your links I still see android documentation…

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 20, 2021, 10:45pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/31 "2021-01-20T22:45:00Z")

</div>

Hey @tmiskiew,

Here are the links that have been updated:  
[getShareSourceList](https://marketplacefront.zoom.us/sdk/meeting/macos/interface_zoom_s_d_k_a_s_controller.html#a0af630b5112df43e1d5a9978788370d4)  
[onSharingStatus:User:](https://marketplacefront.zoom.us/sdk/meeting/macos/protocol_zoom_s_d_k_a_s_controller_delegate_01-p.html#ad4d13d7ca248098d4e5ec340704eb7bc)

> [@ZoomSDKError 4 on UI functions](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/26):
>
> Hey @j_a_z_z, To get the userID’s of the users who are actively sharing, you can call - [getShareSourceList](https://marketplacefront.zoom.us/sdk/meeting/macos/interface_zoom_s_d_k_a_s_controller.html#a0af630b5112df43e1d5a9978788370d4) from the ZoomSDKASController. To be alerted that someone started sharing you can use - [onSharingStatus:User:](https://marketplacefront.zoom.us/sdk/meeting/macos/protocol_zoom_s_d_k_a_s_controller_delegate_01-p.html#ad4d13d7ca248098d4e5ec340704eb7bc) To assign your object as a delegate you would call: ZoomSDKMeetingService\* meetingService = [[ZoomSDK sharedSDK] getMeetingService]; if(meetingService) { let shareController = [meetingService getASController]; shareController.delegate = self; } Thanks! Michael

> [@ZoomSDKError 4 on UI functions](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/22):
>
> Hey @j_a_z_z, Unfortunately, there are not currently interfaces for this. This is only possible if the user is sharing. To be alerted that someone started sharing you can use [onSharingStatus:User:](https://marketplacefront.zoom.us/sdk/meeting/macos/protocol_zoom_s_d_k_a_s_controller_delegate_01-p.html#ad4d13d7ca248098d4e5ec340704eb7bc) Thanks! Michael

These are navigating to the MacOS docs on my end, are they navigating to Android for you?

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![tmiskiew](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tmiskiew/32/9174_2.png) [@tmiskiew](https://devforum.zoom.us/u/tmiskiew)\
**Post date:** [January 20, 2021, 11:04pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/32 "2021-01-20T23:04:20Z")

</div>

Ok thanks. Sorry tapped the wrong ones.

Do they work for you with the latest macOS SDK?

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 20, 2021, 11:14pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/33 "2021-01-20T23:14:25Z")

</div>

Hey @tmiskiew,

I am pulling down a fresh install in a new meeting right now to triple-check 🙂

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 20, 2021, 11:46pm UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/34 "2021-01-20T23:46:40Z")

</div>

Hey @tmiskiew,

We just tested this in the demo app and both getShareSourceList and onSharingStatus worked with the latest version of the SDK.

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![j\_a\_z\_z](https://avatars.discourse-cdn.com/v4/letter/j/439d5e/32.png) [@j\_a\_z\_z](https://devforum.zoom.us/u/j_a_z_z)\
**Post date:** [January 21, 2021, 12:57am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/35 "2021-01-21T00:57:10Z")

</div>

Hey @Michael_Condon,

I just tested again with both SDKs to see the difference, While doing that I figured out the problem was indeed in my code.  
I was setting the delegate in the initialiser of my custom class and seems like `ZoomSDKASController` is `nil` at that time. Now I am setting it right after calling the joinMeeting function and it works fine now.  
But does that mean, the `ZoomSDKASController`, `ZoomSDKMeetingUIController`, `ZoomSDKMeetingActionController` are recreated for every meeting?  
Should I set the delegate every time I start a meeting?

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 21, 2021, 1:43am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/36 "2021-01-21T01:43:38Z")

</div>

Hey @j_a_z_z,

So, an instance of `ZoomSDKMeetingService` will be created after the SDK has been authed/initialized. When the `ZoomSDKMeetingService` is created, it will also create the instances of `ZoomSDKMeetingUIController` and `ZoomSDKMeetingActionController`. These instances will stay around for the duration of the `ZoomSDKMeetingService`.

However, an instance of `ZoomSDKASController` is not created until the user has been admitted into a meeting. From there the `ZoomSDKASController` will stay around for the duration of the `ZoomSDKMeetingService`. So  
`[[[ZoomSDK sharedSDK] getMeetingService] getASController]` will return nil until the user has entered a meeting.

> [@j\_a\_z\_z](#):
>
> Should I set the delegate every time I start a meeting?

Yes for the ZoomSDKASController delegate. Only because `ZoomSDKASController` will be nil until the user has joined into a meeting. If the user is going to be joining multiple meetings throughout the app’s lifecycle, you could keep resetting the delegate every time the user joins. However, the instance of `ZoomSDKASController` remains constant after the first meeting.

Thanks!  
Michael

---

<div class="post-metadata">

**Author:** ![j\_a\_z\_z](https://avatars.discourse-cdn.com/v4/letter/j/439d5e/32.png) [@j\_a\_z\_z](https://devforum.zoom.us/u/j_a_z_z)\
**Post date:** [January 21, 2021, 1:58am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/37 "2021-01-21T01:58:32Z")

</div>

Thanks @Michael_Condon  
Now it is clear to me. I was expecting it to behave like `ZoomSDKMeetingActionController` and `ZoomSDKMeetingActionController` as those delegates are also set in the initialisers.

Thanks for the clarification!

---

<div class="post-metadata">

**Author:** ![Michael\_Condon](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_condon/32/13543_2.png) [@Michael\_Condon](https://devforum.zoom.us/u/Michael_Condon)\
**Post date:** [January 21, 2021, 2:01am UTC](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576/38 "2021-01-21T02:01:07Z")

</div>

Hey @j_a_z_z,

You are welcome 🙂. I totally understand how those can be expected to behave similarly.

Thanks!  
Michael

[Previous page](https://devforum.zoom.us/t/zoomsdkerror-4-on-ui-functions/38576.md?page=1)
