Hello,
I have a website and I need that everyday changes the image background, slideshow and header. Right now I have seven differents macros connected through FTP to the server of a website and each one upload a group of diferent images (background, slidehow, header) from a different directory each one.
First I thought about each macro executing every 8 days but I could'nt find the option. Or another option is randomly.
I have the 7 macros in a folde and I don't know if it is possible to execute a random macro from the folder each day
OR
That to create one macro which executes everyday and randomly chooses a different directory of images.
But I'm still familiarizing myself with the software and code and I need some help.
How to automatize daily changes?
Moderators: JRL, Dorian (MJT support)
Re: How to automatize daily changes?
Reading some posts of the forum I finally write what I need. I share it in case it helps some beginner
//number of variables
Let>NumItems=7
//variables
Let>Chars_1=1
Let>Chars_2=2
Let>Chars_3=3
Let>Chars_4=4
Let>Chars_5=5
Let>Chars_6=6
Let>Chars_7=7
//create a string where I'll save the result
Let>NewString={""}
//pick a random number from 1 to 7
Random>NumItems,RandID
//Saving the final variable (Char_ + number)
Let>NewString=Chars_%RandID%
//publishing the images...
FTPPutFile>ftp.xxx.com,Macroscheduler,xxx,xx,\\path\Documents\Web\template\tpl%NewString%\images\*.*,\images\,,I
Wait>15
//number of variables
Let>NumItems=7
//variables
Let>Chars_1=1
Let>Chars_2=2
Let>Chars_3=3
Let>Chars_4=4
Let>Chars_5=5
Let>Chars_6=6
Let>Chars_7=7
//create a string where I'll save the result
Let>NewString={""}
//pick a random number from 1 to 7
Random>NumItems,RandID
//Saving the final variable (Char_ + number)
Let>NewString=Chars_%RandID%
//publishing the images...
FTPPutFile>ftp.xxx.com,Macroscheduler,xxx,xx,\\path\Documents\Web\template\tpl%NewString%\images\*.*,\images\,,I
Wait>15