Is there a way to email the content of a folder ( Filename and Size) using robotask. Need to run this task every morning.
Rgds,
Kash
Export/Email file name and size of a spedific folder
Re: Export/Email file name and size of a spedific folder
Yes, of course.
Look at the example below
Save the task into a file and use menu Task -> import in order to import into RoboTask
Of course you should change parameters of the action "Send email" to your own.
Do not forget to enable the task after importing.
Look at the example below
Code: Select all
;*****************************
;* RoboTask Task file
;* Do not edit in text editor!
;*****************************
[Root]
ActionAfterRun=INTEGER|0
Actions=FOLDER
Automat=INTEGER|-1
CatID=INTEGER|2099193306
Comment=STRINGLIST
ContinueOnError=INTEGER|0
Events=FOLDER
ExternalName=STRING|"Task417"
Hide=INTEGER|0
ID=INTEGER|604131886
LogOnAsUser=INTEGER|1
Name=STRING|"Send content of the folder"
OnErrorTaskID=INTEGER|0
Priority=INTEGER|3
RunOnClose=INTEGER|0
RunOnStartup=INTEGER|0
ToLog=INTEGER|3
WriteGeneralLog=INTEGER|0
[Actions]
Action1=FOLDER
Action2=FOLDER
Action3=FOLDER
Action4=FOLDER
Action5=FOLDER
Action6=FOLDER
Action7=FOLDER
Action8=FOLDER
[Actions\Action1]
ActionID=STRING|"A_VARIABLES_CREATE"
Enabled=INTEGER|-1
Name=STRING|"Create local variable ""FOLDER"" with value ""D:\incoming"""
Params=FOLDER
[Actions\Action1\Params]
expand=STRING|"0"
varkind=STRING|"1"
varname=STRING|"FOLDER"
varvalue=STRING|"D:\incoming"
[Actions\Action2]
ActionID=STRING|"A_VARIABLES_CREATE"
Enabled=INTEGER|-1
Name=STRING|"Create local variable ""TEXT"" with value ""Content of the folder {Folder}:{EOL}{EOL}"""
Params=FOLDER
[Actions\Action2\Params]
expand=STRING|"1"
varkind=STRING|"1"
varname=STRING|"TEXT"
varvalue=STRING|"Content of the folder {Folder}:{EOL}{EOL}"
[Actions\Action3]
ActionID=STRING|"A_VARIABLES_CREATE"
Enabled=INTEGER|-1
Name=STRING|"Create local variable ""FILENAME"" with value """""
Params=FOLDER
[Actions\Action3\Params]
expand=STRING|"0"
varkind=STRING|"1"
varname=STRING|"FILENAME"
[Actions\Action4]
ActionID=STRING|"A_VARIABLES_CREATE"
Enabled=INTEGER|-1
Name=STRING|"Create local variable ""FILESIZE"" with value """""
Params=FOLDER
[Actions\Action4\Params]
expand=STRING|"0"
varkind=STRING|"1"
varname=STRING|"FILESIZE"
[Actions\Action5]
ActionID=STRING|"A_LOOP_FILE"
Enabled=INTEGER|-1
Name=STRING|"File Loop"
Params=FOLDER
[Actions\Action5\Params]
createmode=STRING|"1"
date1=STRING|"20130830"
date2=STRING|"20130830"
destvar=STRING|"FILENAME"
DuringDays=STRING|"1"
DuringHours=STRING|"1"
DuringMinutes=STRING|"1"
DuringMonths=STRING|"1"
file0=STRING|"{Folder}\*.*"
filecount=STRING|"1"
OlderDays=STRING|"1"
OlderHours=STRING|"1"
OlderMinutes=STRING|"1"
OlderMonths=STRING|"1"
savesize=STRING|"1"
savevar=STRING|"FILESIZE"
searchkind=STRING|"0"
sort=STRING|"1"
sortby=STRING|"0"
sortorder=STRING|"0"
subdirs=STRING|"1"
timesize=STRING|"0"
WithoutPath=STRING|"0"
[Actions\Action6]
ActionID=STRING|"A_VARIABLES_SET"
Enabled=INTEGER|-1
Name=STRING|"Set variable ""TEXT"" with value ""{TEXT}{FILENAME}; {FILESIZE} bytes{eol}"""
Params=FOLDER
[Actions\Action6\Params]
expand=STRING|"1"
varname=STRING|"TEXT"
varvalue=STRING|"{TEXT}{FILENAME}; {FILESIZE} bytes{eol}"
[Actions\Action7]
ActionID=STRING|"A_LOOP_END"
Enabled=INTEGER|-1
Name=STRING|"End Loop"
[Actions\Action8]
ActionID=STRING|"A_INET_SENDMAIL"
Enabled=INTEGER|-1
Name=STRING|"Send Email"
Params=FOLDER
[Actions\Action8\Params]
attachcount=STRING|"0"
auth=STRING|"0"
charset=STRING|"Windows-1252"
from=STRING|"user@domain.com"
host=STRING|"mail.domain.com"
html=STRING|"0"
msg0=STRING|"{text}"
msgcount=STRING|"1"
password=STRING|"2565725452246852545525706"
passwordmode=STRING|"0"
port=STRING|"25"
SSL=STRING|"0"
subject=STRING|"List of folder {folder}"
to=STRING|"admin@domain.com"
[Events]
Event1=FOLDER
[Events\Event1]
Enabled=INTEGER|-1
EventID=STRING|"E_GENERAL_SHEDULER"
Params=FOLDER
UnigueID=INTEGER|16445953
[Events\Event1\Params]
id=STRING|"INVN7UIA"
periodicity=STRING|"0"
startdate=STRING|"41516"
time0=STRING|"34200000"
timecount=STRING|"1"
Of course you should change parameters of the action "Send email" to your own.
Do not forget to enable the task after importing.
Oleg Yershov