Javascript Namespace is not defined if we try to use external lib integration by using Kony FFI in Kony Visualizer Ent 8 sp1

This thread was migrated from an old forum. It may contain information that are no longer valid. For further assistance, please post a new question or open a support ticket from the Customer Support portal.

I try to use external libs by using FFI, for example using this article:

https://basecamp.kony.com/s/article-detail/a046A000001lz4CQAQ/android-calendar-events-app-using-ffi

but I see the error "Unhandled Exception: NativeCalendar is not defined" when click on date. It was tested on two different PCs and android devices. Maybe somebody has any recomendations? Thanks.

Tested in Kony Visualizer 7.0, 7.3, 8.1, 8.2 with two example apps:

CalenderWidget https://basecamp.kony.com/s/article-detail/a046A000001lz4CQAQ/android-calendar-events-app-using-ffi

ScanditDemo https://github.com/kony/Barcode-Scanner-with-Scandit-library

Don't work

Hi,

Please share your application and the FFI library.

And are you running this app on Functional Preview?

Also you can try the sample for calendar events app present at the below location for your reference :

https://github.com/KonyDev/GetAndroidDeviceCalendarEvent_using_FFI

Thanks,

Hi! Thank you for your answer! I already tried your sample with calendar events ( article: https://basecamp.kony.com/s/article-detail/a046A000001lz4CQAQ/android-calendar-events-app-using-ffi github: https://github.com/KonyDev/GetAndroidDeviceCalendarEvent_using_FFI ) and it doesn't work.

Hi ,

FFI based apps cannot be run on Functional Preview app available in play store.However, you can use the "Preview" feature of Kony Visualizer.

For this please follow the steps under "Previewing Child Apps with FFIs in Functional Preview" from the below page

http://docs.kony.com/konylibrary/visualizer/visualizer_user_guide/Default.htm#Foreign_Function_Interface_JS.htm

Thanks.

Thanks! Now, I don't view my device in Preferences -> Kony Visualiser -> Devices -> Android, but command "adb devices -l" shows me my phone. When I connect my phone to Kony Visualiser, I'll try Calendar on my device and write here later.

Hi,

Now the Kony Visualiser shows me my Android device in list, but when I try to run the project on it (Preview -> Launch emulator -> mydevice) Visualiser hangs and happens nothing more. May be it writes logs? Where I can find them?

Hi,

Please try stopping adb.exe process in task manager and launch again.

You can view the logs at <C:\Users\<your user>\Kony Visualizer\vizdata\logs>.

Hi!

Yes, I tried to kill this process (it starts when I find the devices in Preferences) and tried to reboot my PC, but nothing helps. Thank you for the log files location!

Working scenario:

  1. Open "Product" - "Emulators & Devices configuration"
  2. Go to "Kony Visualizer - Devices - Android"
  3. In Windows Task manager kill the process "adb.exe"
  4. Press "Refresh Connected Devices List"
  5. Select your device, press Ok
  6. "Product" - "Build"
  7. "Product" - "Run as" - "%YourDeviceName%" - "Native"
  8. Wait until Visualizer hangs
  9. In Windows Task manager kill the process "adb.exe"
  10. Wait for build and deploy to your Android device

Omg....