February 5, 2018 asmith

Using JavaScript Components in Omnis: Apps Gallery & Comps SDK

To create a web or mobile app in Omnis Studio you have to create a JavaScript Remote form and add JavaScript components to the form: you then need to add methods and the database layer in your Omnis code. The remote form (the app) can be displayed in a standard web browser on more or less any device, including a desktop computer, tablet or phone: remote forms are rendered in the browser via the JavaScript Client, which is embedded into a simple HTML page. So the quality and attractiveness of your app very much depends on the range of JavaScript components available in Omnis. Fortunately, there are over 30 ready-made JavaScript components in Omnis Studio and you can create your own using third-party “open source” code.

Example JavaScript Components

The JavaScript Apps Gallery on the Omnis website showcases many of the JavaScript Components and provides a sample app which you can download and run in the latest version of Omnis Studio. The gallery features sample apps for Sliders, Timers, Grids, Lists, Maps, a PDF Viewer and various types of Chart. View the gallery here:
All of the components are documented on the Omnis website in the ‘JavaScript Components’ chapter in the ‘Creating Web & Mobile Apps’ manual.

Creating controls using JSON

In the latest version of Studio, Omnis Studio 8.1, you can define your own remote form controls using JSON and JavaScript, and use them on JavaScript Remote forms in your web and mobile applications. The easiest way to implement new JS controls is to wrap ready-made JavaScript components, available from a third-party, and use them in your Omnis web or mobile apps. This new method of creating JavaScript components provides an alternative to creating external components using C++ and our JavaScript Components SDK.
There is a tech note on the Omnis website that describes the process of using a ready-made JS component in Omnis. The tech note is here:

  • TNJC0009: Adding Ready-made JavaScript components to Omnis

In the tech note we have taken a ready-made JS component which displays a Star rating, and created a JSON wrapper for it.

Try it for yourself

You can get a 90-day free trial of Omnis Studio so you can have a go at building your own JavaScript web or mobile app using Omnis. Sign up for the free trial here:

, , , ,