Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Can you run a script in FM from the web?

Featured Replies

I have a little script that formats a work order number to 'YYYYMMDD.n' where 'n' is the nth work order submitted for the day. I want the script to be executed when a new record is created in the database. The users enter work orders via a custom web form that creates a new record in the database. How can I do this?

Thanks!

Re: Can you run a script in FM from the web?

The answer is Yes.

re: How can I do this?

The syntax can be found in the CDMLRdb which you were advised to get.

re: script that formats a work order number to 'YYYYMMDD.n' where 'n'

Whatever the script does cannot be important to the solution because of the issues with the way ScriptMaker handles events and the way CDML does not recognize event failures. You will find this issue widely discussed in the Internet forums. Do a little reading on the subject before you proceed. down this path.

I believe that calculation field will do the trick and no script is necessary.

Something like:

Year(DateC) & Right( "0" & Month( DateC ), 2) & Right( "0" & Day( DateC ), 2) & "." & Counter

Where DateC is creation date and Counter is just serial number field.

HTH

Anatoli, you've made it too easy. laugh.gif

Did I? I am sorry if I took some fun from the research smile.gif

  • Author

Thanks!

Bottom line is, avoid using scripts on the web. Do everything with calculations if possible. The hosting company I use will not host a database that runs scripts from the web. It crashes their servers!

Perhaps the problem is with developers who do not know how to run ScriptMaker events safely on the www.

For a hosting service to allow ScriptMaker events to be run, every solution sharing ScriptMaker and WC would have to be coordinated in the solution. Since that could involve a coordination of many diverse entities who might want to share their solution, it is not realistic for a hosting service to allow its clients to run ScriptMaker script events.

To run ScriptMaker events successfully on the www one should host one's own db files/format files, which, in the long run is cheaper and more practical than using a hosting service.

ScriptMaker events can be run on the www safely and successfully. You can figure out how to do it in just four to eight weeks.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.