# \[Bug report\] java.lang.IllegalAccessError when call startMeetingWithParams in Kotlin

**URL:** <https://devforum.zoom.us/t/bug-report-java-lang-illegalaccesserror-when-call-startmeetingwithparams-in-kotlin/4984>\
**Category:** Meeting SDK\
**Created:** [July 11, 2019, 5:21pm UTC](https://devforum.zoom.us/t/bug-report-java-lang-illegalaccesserror-when-call-startmeetingwithparams-in-kotlin/4984 "2019-07-11T17:21:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jiulongw](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/jiulongw/32/1121_2.png) [@jiulongw](https://devforum.zoom.us/u/jiulongw)\
**Post date:** [July 11, 2019, 5:21pm UTC](https://devforum.zoom.us/t/bug-report-java-lang-illegalaccesserror-when-call-startmeetingwithparams-in-kotlin/4984/1 "2019-07-11T17:21:15Z")

</div>

**Description**  
Android runtime throws `java.lang.IllegalAccessError` on `meetingService.startMeetingWithParams(context, params, opts)` call. I was using `StartMeetingParamsWithoutLogin`.

```auto
java.lang.IllegalAccessError: Illegal class access: '(my class)'
attempting to access 'us.zoom.sdk.StartMeetingParams'
(declaration of '(my class)' appears in /data/app/(my apk).apk)

```

**This only happens in Kotlin** (I haven’t dig into generated bytecode but I guess Kotlin is doing some runtime parameter check).

I believe this is caused by public class `StartMeetingParamsWithoutLogin` extends `StartMeetingParams` which is a package level class (no public modifier for `StartMeetingParams`).

I have to put this call to a Java file to work-around this issue. I suggest to make `StartMeetingParams` a public class.

**Which version?**  
v4.3.1.47200.0322

**To Reproduce(If applicable)**  
Write android app using Kotlin and make call to startMeetingWithParams, app will crash.

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [July 11, 2019, 5:48pm UTC](https://devforum.zoom.us/t/bug-report-java-lang-illegalaccesserror-when-call-startmeetingwithparams-in-kotlin/4984/2 "2019-07-11T17:48:22Z")

</div>

Hi jiulong,

Thanks for the post. Yes, this is a known issue for using Java libraries with Kotlin because of the following:

**Java allows accessing protected members from other classes in the same package and Kotlin doesn’t, so Java classes will have broader access to the code**

I will pass this information to our engineers and see how can we make our SDK compatible with Kotlin.

Thanks!

---

<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, 6:33pm UTC](https://devforum.zoom.us/t/bug-report-java-lang-illegalaccesserror-when-call-startmeetingwithparams-in-kotlin/4984/3 "2020-08-21T18:33:41Z")

</div>

Closed on August 21, 2020, 6:33pm UTC


