Monday, February 14

Activating a customized button without using script

Precede the Method Invoked name with “EventMethod” in the control.

For example a button with Method Invoked = “Click” should actually have Method Invoked = “EventMethodClick” to get itself activated on the applet without using any script in the “WebApplet_PreCanInvokeMethod”.

Pop up different applets from the same control based on condition

Steps to configure:

1. The Control should be created with the following details:
Method Invoked: ShowPopup
HTML Type: MiniButton

2. The control should be added to the Applet Web Layout.

3. In WebApplet_PreCanInvokeMethod of the Applet Server Script, CanInvoke should be set to 'TRUE' and return (CancelOperation) should be mentioned.

4. In the Applet User Property a new record with the following details should be created :
Name: Named Method: ShowPopup
Value: 'INVOKE', 'ShowPopup', 'IIF([Field Name] = "Value","Popup Applet A","Popup Applet B")', 'Edit List'

If the value of the field given in the Field Name matches with the value given in Value then the Popup Applet A will get invoked, otherwise Popup Applet B will get invoked. Both Popup Applets will get invoked in the Edit List mode.

Thursday, January 20

How to To make a field read-only in smartscripts

From the application-level menu, Navigate to > Site Map > Administration - SmartScript > Scripts.
In the Scripts list, query to find the SmartScript you want to modify.
Click the Programs view tab.
From the Programs list, select Script_Open.
In the Program Language field, select eScript, and then click Save.
In the eScript form, use the script function SetQuestionEnable(false) to set the question to read-only. Verify that each read-only field has a SetQuestionEnable(false) statement attached to it.

How to set more than 500 values in static picklist?


In Tools, at the business component called Picklist Generic, you will notice that it has a property called Prefetch Size, which is by default set to 500.

There is also a related property called Maximum Cursor Size, which should be set to the same value as Prefetch Size.If you change these values, you will be able to change the number of values displayed in the picklist.

Exposing more List Columns in List Applets


Requirement : Requirement is to expose more List Columns in the List applet.


Solution  : For exposing more List columns in List applet we have to change the “count” property in the “For” loop of the CCListBody.swt and CCListHeader.swt files. We can add any number of List columns in List applet. But for performance and usability reasons, a maximum of 40 list columns should bound to a list applet web template.

Blogger Widgets