DayBackForFileMaker

Event Actions

DayBackForFileMaker.EventActions History

Hide minor edits - Show changes to markup

May 19, 2023, at 04:28 PM by 192.88.134.15 -
Changed lines 5-6 from:

https://www.seedcode.com/rootimages/stikipad/dayback/TooltipPivotDetail.png

to:

https://archive.seedcode.com/rootimages/stikipad/dayback/TooltipPivotDetail.png

Changed line 23 from:

https://www.seedcode.com/rootimages/stikipad/dayback/EventActionCalc.png

to:

https://archive.seedcode.com/rootimages/stikipad/dayback/EventActionCalc.png

January 09, 2020, at 12:11 AM by KC Embrey - FIxed additional field token reference
Changed line 49 from:

If you'd like to include one or more of your additional fields in the tooltip, you reference those somewhat differently: [['fieldname']] where fieldname is the actual FileMaker field name without the table occurrence name in front of it. So you might do this:

to:

If you'd like to include one or more of your additional fields in the tooltip, you reference those somewhat differently: '[[fieldname]]' where fieldname is the actual FileMaker field name without the table occurrence name in front of it. So you might do this:

Changed lines 49-51 from:

If you'd like to include one or more of your additional fields in the tooltip, you reference those somewhat differently: 'fieldname'? where fieldname is the actual FileMaker field name without the table occurrence name in front of it. So you might do this:

"javascript:dbk.tooltip('Event Notes: notes?');"

to:

If you'd like to include one or more of your additional fields in the tooltip, you reference those somewhat differently: [['fieldname']] where fieldname is the actual FileMaker field name without the table occurrence name in front of it. So you might do this:

"javascript:dbk.tooltip(event.title + '<br />' + event.resource + '<br />' + '[[notes]]');"
Added line 48:
August 19, 2019, at 04:28 PM by KC Embrey - Added note on Additional Fields
Added lines 46-51:

Additional Fields If you'd like to include one or more of your additional fields in the tooltip, you reference those somewhat differently: 'fieldname'? where fieldname is the actual FileMaker field name without the table occurrence name in front of it. So you might do this:

"javascript:dbk.tooltip('Event Notes: notes?');"

January 05, 2019, at 12:48 AM by 192.88.134.15 -
Changed lines 45-49 from:

You'll find a list of all these under-the-hood names, as well as tips for using them in JavaScript actions here: JavaScript Custom Actions. Note that these names are used anytime you're writing JavaScript to run inside DayBack: in both event actions (behaviors) and custom actions (buttons).

to:

You'll find a list of all these under-the-hood names, as well as tips for using them in JavaScript actions here: JavaScript Custom Actions. Note that these names are used anytime you're writing JavaScript to run inside DayBack: in both event actions (behaviors) and custom actions (buttons).

What kinds of JS objects and methods are availble?

Check this out: ActionObjects.

December 03, 2018, at 08:35 PM by 192.88.134.15 -
Changed line 41 from:

Referencing Fields in Your JavaScript Event Actions

to:

Referencing Fields in Your JavaScript Event Actions ,

December 03, 2018, at 08:22 PM by 192.88.134.15 -
Changed lines 17-18 from:

Enabling event actions.

to:

Enabling Event Actions

Changed line 41 from:

Referencing fields in your JavaScript event actions

to:

Referencing Fields in Your JavaScript Event Actions

December 03, 2018, at 08:21 PM by 192.88.134.15 -
December 03, 2018, at 08:21 PM by 192.88.134.15 -
Changed lines 39-45 from:
4. The last option states the kinds of events that can trigger this action: use this to restrict your action to only editable events, for example.
to:
4. The last option states the kinds of events that can trigger this action: use this to restrict your action to only editable events, for example.

Referencing fields in your JavaScript event actions

Your event actions have access to the event in which they are running and you may want to reference fields from that event in your action. In the tooltip example above, you'll see the title of the event referenced as event.title. That's the under-the-hood name for the event title.

You'll find a list of all these under-the-hood names, as well as tips for using them in JavaScript actions here: JavaScript Custom Actions. Note that these names are used anytime you're writing JavaScript to run inside DayBack: in both event actions (behaviors) and custom actions (buttons).

December 03, 2018, at 08:16 PM by 192.88.134.15 -
December 03, 2018, at 08:16 PM by 192.88.134.15 -
Changed line 39 from:
4. The last option states the kinds of events that this action can apply to: use this to restrict your action to only editable events, for example.
to:
4. The last option states the kinds of events that can trigger this action: use this to restrict your action to only editable events, for example.
December 03, 2018, at 08:15 PM by 192.88.134.15 -
Changed lines 37-39 from:
3. A flag, true or false, to prevent the default action. For example, when you click on an event, DayBack normally shows you the event in popover or opens the event in your layout: that's the "default action". If you wanted to do something completely different on click, like just show a tooltip, you'd set this flag to true.
to:
3. A flag, true or false, to prevent the default action. For example, when you click on an event, DayBack normally shows you the event in popover or opens the event in your layout: that's the "default action". If you wanted to do something completely different on click, like just show a tooltip, you'd set this flag to true.
4. The last option states the kinds of events that this action can apply to: use this to restrict your action to only editable events, for example.
December 03, 2018, at 08:14 PM by 192.88.134.15 -
Changed lines 25-37 from:

Eah

to:

Each action has four elements:

1. The trigger name, like "On Event Hover" which can be any of the 6 action names above.
2. The action itself which is usually a FileMaker script name in the form "ScriptName" ; or inline JavaScript as shown in the scerenshot above. For inline Javascript, the JS follows the word "javascript" like this:
"javascript:dbk.tooltip(event.title);"
You can also reference JavaScript by exporting a JS file and then using the filename in your event action. This is the same way you'd export files for custom actions and is described here. Then you can reference your JS like this:
3. A flag, true or false, to prevent the default action. For example, when you click on an event, DayBack normally shows you the event in popover or opens the event in your layout: that's the "default action". If you wanted to do something completely different on click, like just show a tooltip, you'd set this flag to true.
December 03, 2018, at 08:03 PM by 192.88.134.15 -
Changed lines 15-25 from:

Note that many of the actions above are already running FileMaker scripts: when you drag and event to edit it, for example, a FileMaker script makes that edit. So in most cases you'll want to turn on the FileMaker script debugger and edit or branch the FileMaker script that is already being called. (Here's how we do that: movie.)

to:

Note that many of the actions above are already running FileMaker scripts: when you drag and event to edit it, for example, a FileMaker script makes that edit. So in most cases you'll want to turn on the FileMaker script debugger and edit or branch the FileMaker script that is already being called. (Here's how we do that: movie.)

Enabling event actions.

Event actions were introduced as an in-app update in version 10.42

Each source can have its own Event Actions and you'll specify them in the script "Load Source Settings at Startup --- Describe Your Sources Here ---". Find the comment "Event actions for WebViewer events..." at about line 32 and add your action in the SetVariable line that follows. Here is what that SetVariable calc looks like if we're adding an On Event Hover action to show a tooltip:

https://www.seedcode.com/rootimages/stikipad/dayback/EventActionCalc.png

Eah

December 03, 2018, at 07:56 PM by 192.88.134.15 -
Changed line 15 from:

Note that many of the actions above also run FileMaker scripts, so in most cases you'll want to turn on the FileMaker script debugger and edit or branch the FileMaker script that is already being called. (Here's how we do that: movie.)

to:

Note that many of the actions above are already running FileMaker scripts: when you drag and event to edit it, for example, a FileMaker script makes that edit. So in most cases you'll want to turn on the FileMaker script debugger and edit or branch the FileMaker script that is already being called. (Here's how we do that: movie.)

December 03, 2018, at 07:55 PM by 192.88.134.15 -
Added line 15:

Note that many of the actions above also run FileMaker scripts, so in most cases you'll want to turn on the FileMaker script debugger and edit or branch the FileMaker script that is already being called. (Here's how we do that: movie.)

December 03, 2018, at 07:41 PM by 192.88.134.15 -
December 03, 2018, at 07:41 PM by 192.88.134.15 -
Changed lines 1-14 from:

Coming soon!

to:

Overview: What Are Event Actions?

Event Actions let you run FileMaker scripts or run JavaScript when an event takes place in DayBack. "Events" are things users do, like hovering over an event, which can now call a script using the "On Event Hover" action. You can use that to call a tootip as described here: Tooltips.

https://www.seedcode.com/rootimages/stikipad/dayback/TooltipPivotDetail.png

The actions available are:

On Event Hover
On Event Create
On Event Click
Before Event Save
On Event Save
On Event Delete
November 30, 2018, at 03:16 AM by 192.88.134.15 -
Added line 1:

Coming soon!

(855) SEEDCODE
[email protected]
Follow us: