'form_file': Form File to Be Used by Lycia LowCode

'form_file' Setting Overview

Specifying the Form File Used by LyciaLowCode

'form_file' Setting Overview

There are three ways to use a form for interacting with Lycia LowCode:

1. Use a currently opened or currently focused form (the form is opened / focused somewhere in the 4GL sources prior to invoking the LowCode function call Interact()):

DEFINE iForm InteractForm

DEFINE l_settings InteractForm_Settings #required if you want to change the default behaviour of LLC

...

OPEN WINDOW WITH FORM "form/myForm"...

...

# To invoke the LLC engine, you can use either use Interact() or InteractForm()

CALL iForm.Interact()

# OR

CALL InteractForm(<l_settings>)

2. Call the function InteractFormFile() and specify the form file as a function argument:

CALL InteractFormFile("form/myForm")

#InteractFormFile is a wrapper function for simple form interactions

On that function call, Lycia LowCode will open the form window.

3. Specify the form file as Lycia LowCode setting:

DEFINE l_settings InteractForm_Settings

LET l_settings.form_file = "form/myForm"

CALL InteractForm(<l_settings>)

 

Return to top

Specifying the Form File Used by Lycia LowCode

Note: Before proceeding, get acquainted with the Settings Levels section of LyciaLowCode Settings page (the concept of scopes is essential for configuring multiple interactions and the multitable support).

The definitions like LET <setting_variable>.<setting_name> = <value> refer to the InteractForm_Settings level, while LET <setting_variable>.views["<db_table_name>"].<setting_name> = <value> refers to the View level.

This setting can be defined for:

InteractForm_Settings level: Yes

View level: No

form_file defines a path to the form file that should be opened and used for interaction. It’s a mandatory property for Interact() function of the InteractForm record and should be set before calling the function InteractForm(<settings_rec>).

This setting is ignored if you use InteractCurrentForm() function.

Note: The form_file setting is optional. If it’s not set, Lycia LowCode will use the currently open / focused form.

Setting format:

InteractForm_Settings.form_file STRING

Example:

LET l_settings.form_file = "../db_cms_activity/db_cms_activity_rec"

l_settings here is the name for the settings record you define, and "../db_cms_activity/db_cms_activity_rec" is a path and a form file to use.

Note: Alternatively, you can specify this setting in JSON array in .fm2 form file by the following example: Defining Settings in .fm2 Form File.

 

Return to top

 

Contact Us

Privacy Policy

Copyright © 2024 Querix, (UK) Ltd.