Reputation: 509
I installed the Calendar Library with the preferences GUI in Eclipse and called Refresh CN1 Libs. The following code compiles fine - but crashes the App on my iOS-device when hasPermissions() is called.
Do you have any idea?
try
{
DeviceCalendar tmpDCal = DeviceCalendar.getInstance();
Message.showInformation("tmpDCal = " + tmpDCal == null ? "null" : "instance");
if (tmpDCal != null)
{
if (tmpDCal.hasPermissions())
{
// TODO
}
else
Message.showInformation("No rights");
}
}
catch (Exception e)
{
Message.showInformation("Exception: " + e.getMessage());
}
Upvotes: 2
Views: 28
Reputation: 52760
That library predated the migration to xcode 9.2. I'm guessing it needs an update with the new build hints for ios.NS*.
See this https://www.codenameone.com/blog/xcode-9-mode.html
Try adding the calendar description build hint, if that doesn't work you can try to confirm that hypothesis by compiling with 7.3 and seeing if it works there. Either way file an issue with the findings as we can add those hints directly to the library.
Upvotes: 0