Hi,
I am not receiving an email when this macro is used
filename_%yyyy%-%mm%-%dd[-1d]%.csv
I am receiving the following message in the email:
Error: Attachment file not found
What is the correct format for the filename please?
Thank you,
Grant
File attachment macro format question
1) It depends on how your file named.
2) you cannot use expressions like %dd[-1d]% for the actions. Such expressions were designed for the tests
3) If you are using "Send e-mail" action assigned to some test like "File/Folder Availability" (i.e. you want to find the file and send it by e-mail), you may use %FileName% macro variable for the action
Regards
Alex
2) you cannot use expressions like %dd[-1d]% for the actions. Such expressions were designed for the tests
3) If you are using "Send e-mail" action assigned to some test like "File/Folder Availability" (i.e. you want to find the file and send it by e-mail), you may use %FileName% macro variable for the action
Regards
Alex
-
- Posts: 34
- Joined: Mon Apr 28, 2008 10:15 am
Hello Alex,
Sorry I should have mentioned the file name is in the format such as
filename_2009-03-23.csv on the date of 2009-03-24
filename_2009-03-24.csv on the date of 2009-03-25
or
filename_yyyy-mm-(the previous day).csv
What would the macro be for this please?
Thanking you in advance for your time.
Grant
Sorry I should have mentioned the file name is in the format such as
filename_2009-03-23.csv on the date of 2009-03-24
filename_2009-03-24.csv on the date of 2009-03-25
or
filename_yyyy-mm-(the previous day).csv
What would the macro be for this please?
Thanking you in advance for your time.
Grant
As I said you cannot use expressions like %dd[-1d]% for the actions. Such expressions were designed for the tests.
If you are using "Send e-mail" action assigned to some test like "File/Folder Availability" (i.e. you want to find the file and send it by e-mail), you may use %FileName% macro variable for the action.
What test method triggers this action?
Regards
Alex
If you are using "Send e-mail" action assigned to some test like "File/Folder Availability" (i.e. you want to find the file and send it by e-mail), you may use %FileName% macro variable for the action.
What test method triggers this action?
Regards
Alex
-
- Posts: 34
- Joined: Mon Apr 28, 2008 10:15 am
I do apologise Alex, it is indeed a Folder/File Availability test, with details:
Translate Macros: Yes (checkbox selected)
File or Folder Name:
\\theFull\path\TradeSummary_%yyyy%-%mm%-%dd-[1d]%.csv
Action Profile:
Send email with attachment of the file that was tested if it exists.
So I understand that send email Action property requires using %FileName% for the "Attach File"
May I ask if the macro variables can be used in the email Subject please?
In this format: File emailed is dated %dd%/%mm%/%yy%
Translate Macros: Yes (checkbox selected)
File or Folder Name:
\\theFull\path\TradeSummary_%yyyy%-%mm%-%dd-[1d]%.csv
Action Profile:
Send email with attachment of the file that was tested if it exists.
So I understand that send email Action property requires using %FileName% for the "Attach File"
May I ask if the macro variables can be used in the email Subject please?
In this format: File emailed is dated %dd%/%mm%/%yy%
Well, I cannot say it requires. However you may use this variable to send the file detected by "File/Folder Availability" test methodSo I understand that send email Action property requires using %FileName% for the "Attach File"
http://www.ks-soft.net/hostmon.eng/mfra ... .htm#macro
Yes, it should work fineMay I ask if the macro variables can be used in the email Subject please?
In this format: File emailed is dated %dd%/%mm%/%yy%
http://www.ks-soft.net/hostmon.eng/mfra ... m#actEMail
Regards
Alex