Many customers ask us if their frevvo form can automatically create a calendar event. For example, you may want to create a calendar event if your form is used to schedule a meeting or set a deadline.
Solution
While there is no built-in calendar API integration, many modern calendar applications like Google, Outlook, and O365 provide a straightforward method to generate calendar event links. Using a frevvo business rule, you can dynamically generate such a link with date/time data and provide it to your end user.
Here's an example form where the user inputs the event from and to dates/times. The business rule below generates the unique calendar links for three major apps by plugging the frevvo dateTime value into the URL. Click here to download this example form, upload it to your frevvo installation (v11+), and take a closer look.
// Strip the special characters from the dateTime controls for use in google link
var from = dtf.value.replace(/:/g,"").replace(/-/g,"");
var to = dtt.value.replace(/:/g,"").replace(/-/g,"");
//set up Google Calendar Link
GoogleCalLink.value = '<a href="https://calendar.google.com/calendar/render?action=TEMPLATE&dates=' + from + '%2F' + to + '&details=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29&text=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29" target="_blank">Add to Google Calendar</a>';
//set up Outlook Calendar link
OutlookCalLink.value = '<a href="https://outlook.live.com/calendar/0/deeplink/compose?body=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29&enddt=' + dtf.value + '&path=%2Fcalendar%2Faction%2Fcompose&rru=addevent&startdt=' + dtt.value + '&subject=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29" target="_blank">Add to Outlook Calendar</a>';
//set up 0365 Calendar Link
O365CalLink.value = '<a href="https://outlook.office.com/calendar/0/deeplink/compose?body=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29&enddt=' + dtf.value + '&path=%2Fcalendar%2Faction%2Fcompose&rru=addevent&startdt=' + dtt.value + '&subject=frevvo%20Upgrade%20Deadline%20%28old%20license%20expires%29" target="_blank">Add to O365 Calendar</a>';
Tips & Tricks
- Consult your favorite calendar service's documentation for details on URL structure.
- In our example, the event title and description are hard-coded; however, you could make these dynamic using controls in your form just as you do the dates.
- Remember some apps (like Google) require the date/time in a specific format. In this example, we've stripped the colons and dashes from the frevvo dateTime values.
- You can set these up as clickable links on the form, or use the control templates to add a link to your email, Pending Message, or Form Action.
- Another fun way to use calendars with forms is to provide a link to your public appointment/booking page. See this Google documentation, and this Outlook documentation, for how to create the appointment page and get a link for it.
Our Client Services team is standing by to help you integrate with calendar apps for your business. Request help today!
We appreciate you trusting frevvo with your mission-critical applications. It is our goal to always provide you with the highest quality of service possible.
Comments
0 comments
Please sign in to leave a comment.