Holidays Macro

Macro_Mitch

New member
Hello Members, I'm trying to design a macro which when triggered, it prompts the user to enter date in format "01/04" (day and month respectively) and also prompt user to enter Holiday name as string. The values are then stored in a dictionary and can later be changed via the prompt
 

Dm114

Well-known member
Hello Members, I'm trying to design a macro which when triggered, it prompts the user to enter date in format "01/04" (day and month respectively) and also prompt user to enter Holiday name as string. The values are then stored in a dictionary and can later be changed via the prompt
Which of the 2 values will be the key of the dictionary?
 

Dm114

Well-known member
The date. ie 01/04 (day and month respectively)
First, have you had a look to MD Wiki to familiarize with MacroDroid principles and "philosophy"?

Anyway, you first have to create few variables such a Dictionary (Dict), and 2 string variables (s1 and s2).

Then (very simple and synthetic) :
A: Set s1 (user prompt for date)
A: check whether s1 matches a valid date (dd/mm format)
A: Set s2 (user prompt for Holiday name)
A: Set Dict[{lv=s1}]={lv=s2}

Then you'll be able to sophisticate this macro a bit to make it more friendly. 😉
 
Top