Command Line Switches

From Lianjapedia
Revision as of 09:05, 13 August 2014 by Yvonne.milne (Talk | contribs)

Jump to: navigation, search

When creating a desktop shortcut for running Lianja Apps there are several command line options that can be specified.

The following table provides details of the currently available command line options. These can be combined to customize the running of an App e.g.

lianja --app orderprocessing --maximized
lianja myprogram.dbo
lianjaruntime --kiosk --fullscreen --runtimecaption "Our company Apps"

Lianja Command Line Options

Option Arguments Description
--app yourappname Run the specified App.
--args Arg,arg,arg Specify an App specific comma separated list of args to be passed to a runtime script (see filename below). Enclose args in "..." and use single quotes for character args e.g.
--args "'hello','world',2600,{04/04/1953}"
--customer name This will be used as the suffix to display a customized login file and a customized appcenter file. You can copy the existing login.rsp and appcenter.rsp in the cloudserver\appcenter directory and customize these with your own login captions and icons. The name is a suffix that will be appended onto the login.rsp and appcenter.rsp filenames e.g. --customer myco will look for login_myco.rsp and appcenter_myco.rsp respectively.
filename None A filename to run. If no file extension is specified it is assumed to be an App and .lianja is postfixed to it.
--fontsize fontsize Adjust the base fontsize of the App if you are using very high resolution displays and the default font size if too big or too small.
--fullscreen None Run the App fullscreen.
--geometry x,y,width,height Specify the geometry of the window.
--icon Window icon Specify an App specific window icon at runtime.
--kiosk None This will run the Lianja App Center (and login) in full screen kiosk mode with no window frame or title bar. This prevents users from minimizing the window and breaking out of your App in RDP sessions and information kiosks.
--loginapp appname This will load the App immediately after login without displaying the Lianja App Center. This provides you with the ability to replace the Lianja App Center with your own that you have written as a Lianja App or alternatively run an App directly after login bypassing the App Center.
--maximized None Maximize the window.
--noguests None Prevents readonly access to the Apps using the guest/guest login (disables guest login).
--password Password Specify a password for automatic login.
--rdp None This will display the login screen with a plain background (no image) and no progress bar when loading an App.
--reset None Run Lianja App Builder without restoring previous App state.
--runtime None Runs the Lianja App Center.
--runtimecaption Caption text Replaces the "Lianja App Center" caption text in the App Center Home workspace with the specified caption text.
--runtimedir Runtime directory Root directory where Runtime Apps, Library and Data are located, e.g. F:\Lianja\ or /opt/lianja/cloudserver/tenants/public/. This is the equivalent of setting the LIANJA_RUNTIMEDIR environment variable.
--splashscreen Path to a custom splashscreen or "None" to disable Specify an App specific splashscreen at runtime. Note that if --app is specified no splashscreen is displayed unless specified.
--title Window title Specify an App specific window title at runtime.
--username Username Specify a username for automatic login.

To run a custom program specify a file extension of ".dbo". (.dbo files are pre-compiled .prg script files). Remember to add READ EVENTS at the end of the program file otherwise it will just exit and no UI will be displayed.

Note: If you are running some custom program code that is going to take a long time to complete e.g. consolidating inventory, then you can provide feedback to the user via a system tray icon on the desktop e.g.

tray = createObject("SystemTrayIcon")
tray.icon = "app:/myapp.png"
tray.showMessage("Message", "Consolidating inventory...")
// perform some long running operation to consolidate inventory
tray.showMessage("Message", "Consolidation completed...")