Create calendar event using input dialog

Post your questions and help other users.

Moderator: Martin

Post Reply
wfrcrd
Posts: 116
Joined: 27 May 2015 08:57

Create calendar event using input dialog

Post by wfrcrd » 23 Dec 2018 09:14

Hi to everyone,
I need to create a calendar event for TODAY + HH:mm
where HH:mm are the hours and minutes taken from an input dialog.

I don't understand which variable is filled with the input dialog values when I use "time" as the input dialog type,
and I don't know the grammar on the "create new calendar event" to set the TODAY+"time" .

Any help? thank you in advice!

User avatar
digitalstone
Posts: 342
Joined: 21 Oct 2017 12:36
Location: The Netherlands

Re: Create calendar event using input dialog

Post by digitalstone » 23 Dec 2018 13:21

I would say this would get you somewhere:

Code: Select all

{getDate(),dateformat, dd-MM-yyy HH:mm} 
Depends also on in what type of textual field you're typing this into.
In a text-field you would type the exact code from above.

In script form it's slightly different (which still kind of confuses me to this day to be honest):

Code: Select all

getDate("{getDate(),dateformat,dd-MM-yyy HH:mm}", "dd-MM-yyy HH:mm");
Phone: LG Nexus 5X (rooted vanilla Android 7.1.2)

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Create calendar event using input dialog

Post by Martin » 23 Dec 2018 13:24

Hi,

The input dialog provides the selected time in form of a full date+time where the date part is set to today. This is probably what you want so you don't need to add anything at all.
In action Create Calendar Event just use Start/End Type Absolute and enter value in the From-field and something like value+60*60*1000 in the To-field (60*60*1000 is one hour in milliseconds).

Regards,
Martin

wfrcrd
Posts: 116
Joined: 27 May 2015 08:57

Re: Create calendar event using input dialog

Post by wfrcrd » 23 Dec 2018 14:12

Thank you guys,
so "value" was my lucky word (it's easy to find it on the help section after I get the hint! :lol: )

It works pecrfectly.

Post Reply