Action JavaScript in Alpha Anywhere v4 - an automated and intelligent way to quickly and easily write Javascrip for your Mobile and Web apps

Blog



Action JavaScript in Alpha Anywhere v4 - an automated and intelligent way to quickly and easily write Javascrip for your Mobile and Web apps

Saving time and getting results fast is key in modern development.


To address this challenge we have developed a unique and elegant approach called Action JavaScript. Which is a point and click way to building Javscript


 

Action Javascript


Description

Javascript actions available in Alpha Anywhere.

Discussion

 By selecting from a list of predefined actions, and adding your own settings you can create sophisticated Javascript code without writing any code. The code created by Action Javascript can be further edited in the code editor.

 

Name and Description



Message boxDisplays a Javascript alert box on the screen.

Fade Out MessageThe Fade Out Message action displays a message on the screen for a short period of time. The message fades away after a specified duration.

Run ActionThe Run Action runs an action that was defined using Javascript.

Open a Grid componentOpens a grid component in a pop-up window, or in a DIV on the current page. This requires first defining a grid component.

Open a Report, Label or Letter layoutDisplays a report, label or letter layout as a PDF file using the Acrobat PDF reader. The report is displayed in either a pop-up window or in a DIV on the current page.

Open an .a5w page, static HTML page, URL, or PDF document, in a pop-up window or a DIVOpen a document (including .a5w pages, static .html pages, any other web page, e.g. www.google.com, or PDF document) in a modal, or modeless pop-up window, or in a DIV on the page.

Open a UX componentOpens an UX component in a pop-up window, or in a DIV on the current page. (Only new Ajax components can be opened. Old dialogs built in V10 and earilier are not supported.

Open a UX component to Edit Current Record in Grid, or add a new RecordOpen an UX component in a pop-up window, or in a DIV on the current page, to edit the current row in a Grid component or to enter a new record. (Only new Ajax Components can be opened. Old Dialogs in V10 and earlier are not supported.)

Open a UX as an alternate editing view for current recordOpen a UX component in a pop-up window, or in a DIV on the current page, to edit the record currently being edited in the Grid or UX component.

Open a Custom componentOpen a Custom component in a pop-up window, or in a DIV on the current page.

Open a Page Layout componentOpen a Page Layout component in a pop-up window, or in a DIV on the current page.

Open a Google Map componentOpen a Google Map component in a pop-up window, or in a DIV on the current page.

Open a Video Player componentOpen a Video Player component in a pop-up window, or in a DIV on the current page.

Open a Calendar componentOpen a Calendar component in a pop-up window, or in a DIV on the current page.

Open a ImageGallery componentOpen a ImageGallery component in a pop-up window, or in a DIV on the current page.

Open a AppLauncher componentOpen a AppLauncher component in a pop-up window, or in a DIV on the current page.

Inline-JavascriptAllows developer to enter some code.

Ajax CallbackDefine a user-defined ajax callback. The callback can be handled by an Xbasic function that is defined in the component, by a separate .a5w page, or by another page (.e.g., .php, .asp, etc.)

City, State Lookup from Zip CodeFor a given zip code, lookup the city and state on the USPS web site and fill in the city and state in the current record.

Zip Code Lookup from AddressFor a given address, lookup the Zip code on the USPS web site and fill in the current record.

Lookup and Fill-in FieldsLookup values in a table and fill-in fields in the current row from fields in the Lookup Table.

Set Page ContentSet the content in one or more page elements (i.e. 'divs', 'spans', form fields, etc.) to values obtained from fields in a Lookup Table.

File DownloadDownload a file from the server to the user's machine.

Image UploadUpload an image file too the server.

File UploadUpload a file to the server and store a reference to the file in a Grid field, or embed the file in a Drid field.

File Upload - User DefinedUpload one or more files to the server. A server-side event then gets called to allow you to process the uploaded files.

Export to Excel or Ascii or Custom FormatExport data to Excel or Ascii or Custom Format. The Custom format option allows you to define an Xbasic function that creates the file.

Advanced Export to Excel, Word, HTML, or Ascii using a Report DefinitionExport data to Excel, Word, HTML or Ascii using a Report Definition

Import Data from Excel or Ascii fileUpload an Excel or Ascii file and import data into the current Grid or an external table.

Open a Pop-up Ajax Window/OverlayOpen a generic, pop-up window (often called an overlay). The window can be modal, or modeless, and can be populated by making an Ajax callback.

Open a Help WindowOpen a window to display a help topic from the Help Table.

MenusDisplay a dropdown menu.

Geocode an addressMakes an Ajax callback to a web service to geocode an address. Fill in the latitude and longitude fields in the current record with the information.

Google Map MethodThe Google map method action calls a method to perform some action on a Google Map. The map could be the Search Part, or in an Alternate View, for example. actions that you can perform include: Clearing markers, opening or closing an info box, adding a marker to the map, centering the map on an address, and setting the map zoom factor.

Send emailThis javascript action sends an email.

Global UpdateSet the value in a field in all currently visible rows in the Grid.

Global Search and ReplaceSearch and replace values in a field in all currently visible rows in the Grid.

Toggle display of a container or DIV with animationDisplay a Javascript alert box on the screen

Lock/unlock a container, DIV or entire page (by showing an overlay over it)Lock a container, DIV or entire page by showing an overlay over it so that the user can't click on the controls under the overlay, or unlock the element.

Geolocation FunctionsGet geolocation information from the browser and store information in the current Grid/UX component object (e.g. if you are in a Grid, the data is stored in the {grid.object}.geoLocation object). (Requires an HTML5 browser).

Web-sockets Server ActionsPerforms an action on the web-socket server, such as 'Send a message to the web-sockets server'. The message will be received by all UX and Grid components that are listening for web-socket messages and the 'webSocketOnMessage client-side event in all listening components will fire.

Absolute Layout Container - Create PDFCreate a PDF file from the contents of an Absolute Layout container.

Add Alternative Login to Current UserAdd account credentials for an alternative login provider such as Google.

Ajax Callback - Cross DomainDefine a user-defined cross-domain ajax callback. A cross-domain Ajax callback is a callback to a web service in a domain that is different from the domain from which this component was originally loaded.

Chart Control ActionsPerform some action on a Chart control (e.g. refresh the chart, export to PDF, etc.)

Clear a Search a Grid Component that is Embedded into a UX componentFor use in conjunction with the 'Search a Grid Component that is Embedded into a UX' action. Clears the search form in the UX and removes the filter from the embedded Grid.

Client-side Data Cache ActionsPerform some action on an item in the Client-side Data Cache (e.g. read the data, refresh the data, etc.).

Delete Alternative Login for Current UserDelete account credentials for an alternative login provider such as Google.

Delete RecordDeletes a record from the Primary Table in a Data Bound UX component.

Dial Telephone Open SMS clientDial a telephone number or open the SMS client application to send a SMS message.

Display a 'Wait...' messageDisplay a 'wait...' message

Editor ActionsPerform some action on an Editor in an Editor set.

Enable or Disable a ButtonSet a button's state to either enabled, or disabled.

File Upload - Amazon S3 Storage or Alpha Anywhere ServerUpload one or more files to Amazon S3 or to the Alpha Anywhere server.

Filter Records in a List ControlCreate a highly customized 'Search Part' to filter the records shown in a List control.

Form View Control ActionsPerform some action on a Form View control.

Get Primary Key values for Records in QueryExecute a query and then retrieve the primary key values for the parent table of a Data Bound UX component. (IMPORTANT: This action is intended for an event on a UX component).

Google Map Method (UX Component)Call a method to perform some action on a Google Map. Actions that you can perform include: Clearing markers, opening or closing an info box, adding a marker to the map, centering the map on an address, setting the map zoom factor.

Hide a 'Wait...' messageHide a 'wait...' message

Hide/Close a windowClose a pop-up Window.

Hide/Close Container WindowHide (i.e. closes) a Container Window.

Hide/Close PanelOverlay WindowHides (i.e. closes) a PanelOverlay window. You can optionally animate the window as hidden.

Image Capture for List-Detail View - Camera/Photo LibraryThis action is used exclusively for image fields in a List Detail View. Capture an image using the camera, or from the photo library. On devices that don't support a camera, select an image from the filesystem.

Image Capture - Camera/Photo LibraryCapture an image using the camera, or from the photo library. On devices that don't support a camera, select an image from the filesystem. Action calls a function with the Image URI when the image has been obtained.

Image Delete Delete an image from an image field.

Link a Grid that has been embedded into a UX component Unlike the 'Search a Grid Component that is Embedded into a UX' action which applies a filter to an embedded Grid, this action Links the embedded Grid.

List Control Actions Perform some action on a List control (e.g. refresh the List, etc) in a UX Component.

Login with Alternative Login ProviderLogin using account credentials from an alternative login provider such as Google.

Merge data into client-side templateMerge Javascript into a client-side template and set the inner HTML to the result.

New RecordDisplays a new record.

Open a UX component to Edit Current Record in List Control in a UX, or add a new Record to a List Control in a UXOpen a UX component in a pop-up window, or in a DIV on the current page, to eidt the current page, to edit the current row in a List control in a UX component or to enter a new record into a List. (Applies only to Lists based on SQL or DBF data sources).

Panel ActionsPerform some action on a Panel (e.g. setting focus to the next or previous Panel, or to a particular named panel).

PDF from HTMLGet the HTML inside a container and convert to PDF.

PhoneGap - File DownloadDownload one or more files and store the files in the filesystem on the mobile device. Uses the PhoneGap FileTransfer feature. (Only applies to UX components running in a PhoneGap shell.)

PhoneGap - File System ActionsPerforms actions with the mobile device file system such as creating, reading, deleting file, creating directories, etc.(Only applies to UX components running in a PhoneGap shell.)

PhoneGap - File System Actions (File URI Based)Performs actions with the mobile device file system such as creating, reading, deleting file, creating directories, deleteing directories, etc. (Only applies to UX components running in a PhoneGap shell.)

PhoneGap - File UploadUpload one or more files to either the Alpha Anywhere server or to the Amazon S3 using the PhoneGap File Transfer feature. (Only applies to UX components running in a PhoneGap shell.)

PhoneGap - NotificationsDisplay or initiate a native notification (for example, beep, native alert/prompt/confirmation, vibrate, etc.)

PhoneGap - Send SMS messageSend a SMS message.

PhoneGap - SQLite ActionsPerforms actions with the SQLite database on the device. Also allows you to download a SQLite database from the server to the mobile device and create a SQLite database on the server and download it to the device.

Populate Controls in a UX Component with data from TablesPopulate the controls in a UX component with the data from Tables. (IMPORTANT: This action is intended for an event on a UX component).

Populate controls in an UNBOUND UX component with data from a tablePopulates controls in a UX component with data from a table. Use this action (rather than the 'Populate Controls in a UX Component with data from Tables' action) if the UX component has not been bound to a database (see the 'Data Binding' pane in the builder).

Refresh/synchronize embedded UX componentUpdates the argument values in the child UX component and refreshes the data shown in List controls and other controls that are based on data Series. Also causes the embedded UX component's 'onSynchronizeDialog' (client-side) and 'onSynchronize' (server-side) events to fire.

Run a report that is embedded in a UXcomponent using a custom filter for the reportCreate a highly customized 'Search Part' for a Report. Allows you to submit a UX component that contains 'search' fields to compute a filter expression and then run the report using the computed filter expression.

Search a Grid Component that is Embedded into a UX componentCreate a highly customized 'Search Part' for a Grid. Allows you to submit a UX component that contains 'search' fields to compute a filter expression and then filter a Grid component that has been embedded into the UX component.

Show Container WindowShow the contents of a Container Window in a pop-up Window or Panel.

Show PanelOverlay WindowShow a PanelOverlay window. You can optionally animate the window as it is shown.

Stripe - Process Stripe PaymentProcess payment using Stripe.

Update, Insert or Delete data. (for use with an UNBOUND component)Updates, inserts or deletes a record in a table using data submitted from a control on a UX component. The UX component need not have been 'Data Bound' in order to use this action. Contrast this action with the 'Save Submitted Data to Table(s)' action in Server-side action scripting which is used for saving data to tables in a UX component that has been 'Data Bound'.

Video Player Control ActionsPerform some type of action on a video player control.

ViewBox Control ActionsPerform some action on a ViewBox control (e.g. refresh the ViewBox, etc.)

How to TURBO CHARGE Your App Load Speeds With Pre-rendering
Five Ways to Boost Mobile Application Security

About Author

Richard Rabins
Richard Rabins

Co-founder of Alpha Software, Richard Rabins focuses on strategy, sales, and marketing. Richard also served as CEO of SoftQuad International from 1997 to 2001, when it owned Alpha. In addition to his 30 years with the company, Richard played a key role as co-founder, and served as president and chairman of the Massachusetts Software Council (now the Massachusetts Technology Leadership Council), the largest technology trade organization in Massachusetts. Prior to founding Alpha, Richard was a project leader and consultant with Information Resources, Inc. (IRI), and a management consultant with Management Decision Systems, Inc. Richard holds a master's degree in system dynamics from the Sloan School at MIT, and a bachelor's degree in electrical engineering and master's degree in control engineering from University of the Witwatersrand in Johannesburg, South Africa. He has served on the boards of Silent Systems, Legacy Technology and O3B Networks, and is co-founder of Tubifi www.tubifi.com.

Comment

Subscribe To Blog

Subscribe to Email Updates