# How to mute user's audio?

**URL:** <https://devforum.zoom.us/t/how-to-mute-users-audio/646>\
**Category:** Android\
**Tags:** htq, dc\
**Created:** [July 17, 2017, 5:47am UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646 "2017-07-17T05:47:19Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![L11](https://avatars.discourse-cdn.com/v4/letter/l/c68b51/32.png) [@L11](https://devforum.zoom.us/u/L11)\
**Post date:** [July 17, 2017, 5:47am UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/1 "2017-07-17T05:47:19Z")

</div>

Hi, I see there is a function named “setMuted(bool mute)” in  
[https://zoom.github.io/zoom-sdk-android/us/zoom/sdk/InMeetingUserInfo.AudioStatus.html#setMuted-boolean-](https://zoom.github.io/zoom-sdk-android/us/zoom/sdk/InMeetingUserInfo.AudioStatus.html#setMuted-boolean-)

But I am not able to call this from my code ?

I am trying to call this like

```
ZoomSDK.getInstance().getInMeetingService().getMyUserInfo().getAudioStatus().setMuted(true);

but getInMeetingSerivce() is always returning null even if the meeting is on.
```

---

<div class="post-metadata">

**Author:** ![Wei\_Guo1](https://avatars.discourse-cdn.com/v4/letter/w/ec9cab/32.png) [@Wei\_Guo1](https://devforum.zoom.us/u/Wei_Guo1)\
**Post date:** [July 17, 2017, 5:03pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/2 "2017-07-17T17:03:16Z")

</div>

Hi,&nbsp;

please take a look at the following API call :

```
public&nbsp;void&nbsp;muteAudio(boolean&nbsp;mute)

```

Best

---

<div class="post-metadata">

**Author:** ![L11](https://avatars.discourse-cdn.com/v4/letter/l/c68b51/32.png) [@L11](https://devforum.zoom.us/u/L11)\
**Post date:** [July 17, 2017, 5:16pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/3 "2017-07-17T17:16:33Z")

</div>

Hi Wei Guo,  
Thanks for the reply. This function is in MeetingActivity Class.  
Can you help me with code snippet, to call this method from my Home Class.

This is my home class declaration

public class Home extends AppCompatActivity  
implements NavigationView.OnNavigationItemSelectedListener , MeetingServiceListener, ZoomSDKInitializeListener,ConnectivityReceiver.ConnectivityReceiverListener {

}

---

<div class="post-metadata">

**Author:** ![Wei\_Guo1](https://avatars.discourse-cdn.com/v4/letter/w/ec9cab/32.png) [@Wei\_Guo1](https://devforum.zoom.us/u/Wei_Guo1)\
**Post date:** [July 17, 2017, 6:33pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/4 "2017-07-17T18:33:52Z")

</div>

Hi,

Please take a look at Sample code we provided.

Best

&nbsp;

---

<div class="post-metadata">

**Author:** ![L11](https://avatars.discourse-cdn.com/v4/letter/l/c68b51/32.png) [@L11](https://devforum.zoom.us/u/L11)\
**Post date:** [July 17, 2017, 6:56pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/5 "2017-07-17T18:56:37Z")

</div>

Hi Wei,

Which sample code ? Please be more specific. I have already taken 2 pro account and have build the Android App.

I have gone through sample example but Couldn’t find the exact solution.

&nbsp;

Thanks

---

<div class="post-metadata">

**Author:** ![Wei\_Guo1](https://avatars.discourse-cdn.com/v4/letter/w/ec9cab/32.png) [@Wei\_Guo1](https://devforum.zoom.us/u/Wei_Guo1)\
**Post date:** [July 18, 2017, 5:32pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/6 "2017-07-18T17:32:07Z")

</div>

Hi,

sample is available at example2 we provided:&nbsp;[https://github.com/zoom/zoom-sdk-android/blob/master/zoom-mobilertc-adt/example2/src/us/zoom/sdkexample2/MyMeetingActivity.java&nbsp;](https://github.com/zoom/zoom-sdk-android/blob/master/zoom-mobilertc-adt/example2/src/us/zoom/sdkexample2/MyMeetingActivity.java%C2%A0)

In your case, I think under declaration, you need extend MeetingActivity and you can write something like:&nbsp;

| @Override |  
| &nbsp; | public void onMute(boolean mute) { |  
| &nbsp; | return&nbsp;muteAudio(mute); |  
| &nbsp; | } |

Best

---

<div class="post-metadata">

**Author:** ![Wei\_Guo1](https://avatars.discourse-cdn.com/v4/letter/w/ec9cab/32.png) [@Wei\_Guo1](https://devforum.zoom.us/u/Wei_Guo1)\
**Post date:** [July 19, 2017, 12:46am UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/7 "2017-07-19T00:46:35Z")

</div>

Hi,&nbsp;

Do you try to call mute audio method outside meeting process? You can only call Zoom’s inMeetingService in meeting process.&nbsp;

---

<div class="post-metadata">

**Author:** ![L11](https://avatars.discourse-cdn.com/v4/letter/l/c68b51/32.png) [@L11](https://devforum.zoom.us/u/L11)\
**Post date:** [July 19, 2017, 8:16am UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/8 "2017-07-19T08:16:42Z")

</div>

Hi Wei,

Yes

When i extend my Home class from MeetingActivity, Its crashing on onDestroy method.

&nbsp;

E/AndroidRuntime: FATAL EXCEPTION: main  
Process: us.zoom.diyaayaad.zoomsample, PID: 6436  
java.lang.UnsatisfiedLinkError: No implementation found for long com.zipow.videobox.confapp.ConfMgr.getShareObjHandle() (tried Java\_com\_zipow\_videobox\_confapp\_ConfMgr\_getShareObjHandle and Java\_com\_zipow\_videobox\_confapp\_ConfMgr\_getShareObjHandle\_\_)  
at com.zipow.videobox.confapp.ConfMgr.getShareObjHandle(Native Method)  
at com.zipow.videobox.confapp.ConfMgr.getShareObj(ConfMgr.java:173)  
at com.zipow.videobox.ConfActivityNormal.stopShareSession(ConfActivityNormal.java:6197)  
at com.zipow.videobox.ConfActivityNormal.stopShare(ConfActivityNormal.java:6683)  
at com.zipow.videobox.ConfActivityNormal.onDestroy(ConfActivityNormal.java:1158)  
at android.app.Activity.performDestroy(Activity.java:6874)  
at android.app.Instrumentation.callActivityOnDestroy(Instrumentation.java:1175)  
at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:4195)  
at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:4226)  
at android.app.ActivityThread.-wrap6(ActivityThread.java)  
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1534)  
at android.os.Handler.dispatchMessage(Handler.java:102)  
at android.os.Looper.loop(Looper.java:154)  
at android.app.ActivityThread.main(ActivityThread.java:6123)  
at java.lang.reflect.Method.invoke(Native Method)  
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:867)  
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)

&nbsp;

And, Yes I am calling

```
ZoomSDK.getInstance().getInMeetingService().getMyUserInfo().getAudioStatus().setMuted(true);

```

while the meeting is live.&nbsp;

&nbsp;

&nbsp;

&nbsp;

&nbsp;

---

<div class="post-metadata">

**Author:** ![Wei\_Guo1](https://avatars.discourse-cdn.com/v4/letter/w/ec9cab/32.png) [@Wei\_Guo1](https://devforum.zoom.us/u/Wei_Guo1)\
**Post date:** [July 20, 2017, 5:17pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/9 "2017-07-20T17:17:20Z")

</div>

Hi,

I think this issue is because you forget to define the home activity inside meeting process.&nbsp;

Please take a look at the following code sample.

 ![](https://support.zoom.us/hc/user_images/OAU_5ZltLkj3Gzy2YgjNzg.png)  
Best

---

<div class="post-metadata">

**Author:** ![DeveloperBot](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/developerbot/32/12632_2.png) [@DeveloperBot](https://devforum.zoom.us/u/DeveloperBot)\
**Post date:** [August 21, 2020, 5:16pm UTC](https://devforum.zoom.us/t/how-to-mute-users-audio/646/10 "2020-08-21T17:16:37Z")

</div>

Closed on August 21, 2020, 5:16pm UTC


