marios
January 6, 2016, 6:49pm
1
Hi everybody …
I’m trying to setup the email and I have some minor problems.
Searching the forum i find out that we can use entities and tags on subject or in the body so i made this but gives me error
the log file says: “The parameter ‘addresses’ cannot be an empty string.” what addresses ?
[Exception Info 1]
Top-level Exception
Type: System.ArgumentException
Message: The parameter 'addresses' cannot be an empty string.
Parameter name: addresses
Source: System
Stack Trace: at System.Net.Mail.MailAddressCollection.Add(String addresses)
at Samba.Services.Implementations.EMailService.<>c__DisplayClass3_0.<InternalSendEmail>b__0(String x)
at System.Collections.Generic.List`1.ForEach(Action`1 action)
at Samba.Services.Implementations.EMailService.InternalSendEmail(String smtpUser, String smtpPassword, Int32 smtpPort, String toEmailAddress, String ccEmailAddresses, String fromEmailAddress, String subject, String body, String fileName, Boolean bypassSslErrors, MailMessage mail, SmtpClient smtpServer)
at Samba.Services.Implementations.EMailService.SendEmail(String smtpServerAddress, String smtpUser, String smtpPassword, Int32 smtpPort, String toEmailAddress, String ccEmailAddresses, String fromEmailAddress, String subject, String body, String fileName, Boolean deleteFile, Boolean bypassSslErrors, Int32 retryCount, Int32 retryMinutes)
1 Like
QMcKay
January 6, 2016, 6:57pm
2
You used a variable as a To E Mail Address
field which must be supplied in the Rule containing the Send Email
Action.
You should also use a variable for the E Mail Message
portion where you have {ORDERS}, {TICKET TOTAL}
and specify that same content in the Rule. It is not good practice to use Tags directly in Actions.
The error message shows fairly clearly what the issue is:
The parameter 'addresses' cannot be an empty string.
Show the Rule you are using to fire this Action and supply a valid email address for the Action in that Rule.
marios
January 6, 2016, 7:11pm
3
Hi Q i hope you are well
I want to try email when the order state is Delivering
you mean something like this ?
QMcKay
January 6, 2016, 7:17pm
4
Yes.
I still suggest making the Message
field a parameter as well, the same way you have done for the To
field.
Depending on the Rule, you may not have access to the Tags you are using staticly in the Action. Always parameterize the fields of your Actions that will require dynamic updates/content.
marios
January 6, 2016, 7:18pm
5
change it to [:Email Address] same problem
Jesse
January 6, 2016, 7:25pm
6
You must provide a valid email in the CC Email Addresses box as well.
QMcKay
January 6, 2016, 7:37pm
7
Make the parameter fields in the Action as [:variables]
, then set them in the Rule.
marios
January 6, 2016, 10:23pm
8
excuse me Q to “To Address” you wrote me@here.com
i thought that there should be the receiver address …
Receiver is to address isn’t it?
marios
January 6, 2016, 10:38pm
10
Every Customer has different email address and i have a custom entity field called Email Address
For test reasons i enter a valid email address and gives me exactly the same error …
Jesse
January 6, 2016, 10:55pm
11
It would be {ENTITY DATA:Email Address} if custom field was called Email Address. That goes in the To Address inside rule.
marios
January 6, 2016, 10:56pm
12
change it … same problem
also try {ENTITY DATA:Customers:Email Address} with no luck
JTRTech
January 6, 2016, 11:03pm
13
Gmail? I know gmail has very strict security options.
I had to setup a plain email account to setup my printers scan to email option as didn’t support the security protocols gmail uses.
marios
January 6, 2016, 11:05pm
14
you suggest to change email ? and if yes what service ?
JTRTech
January 6, 2016, 11:07pm
15
Gmail lists this for settings;
Port 465 (SSL required)
Port 587 (TLS required) Dynamic IPs allowed
I’m not sure but does samba support TLS
That was the issue I had with printer.
Do you have your own domain name/hosting?
marios
January 6, 2016, 11:08pm
16
yes i have my own domain i’ll give a try
JTRTech
January 6, 2016, 11:11pm
17
There is an option hidden away somewhere to allow less secure connections.
Had to change it for using ms outlook for a client before.
Google lists
Port 465 (SSL required)
Port 587 (TLS required)
Dynamic IPs allowed
My issue was printer didn’t support TLS
Have you got own domain name and website?
If so try a plain basic account on that.
marios
January 6, 2016, 11:13pm
18
I’m going crazy everything i try the same problem
@JTRTech i found that option and cloded it … you can find it here
Allow less secure apps
https://myaccount.google.com/security?utm_source=OGB#signin
marios:
[Exception Info 1]
Top-level Exception
Type: System.ArgumentException
Message: The parameter ‘addresses’ cannot be an empty string.
Parameter name: addresses
Source: System
Stack Trace: at System.Net.Mail.MailAddressCollection.Add(String addresses)
at Samba.Services.Implementations.EMailService.<>c__DisplayClass3_0.<InternalSendEmail>b__0(String x)
at System.Collections.Generic.List1.ForEach(Action
1 action)
at Samba.Services.Implementations.EMailService.InternalSendEmail(String smtpUser, String smtpPassword, Int32 smtpPort, String toEmailAddress, String ccEmailAddresses, String fromEmailAddress, String subject, String body, String fileName, Boolean bypassSslErrors, MailMessage mail, SmtpClient smtpServer)
at Samba.Services.Implementations.EMailService.SendEmail(String smtpServerAddress, String smtpUser, String smtpPassword, Int32 smtpPort, String toEmailAddress, String ccEmailAddresses, String fromEmailAddress, String subject, String body, String fileName, Boolean deleteFile, Boolean bypassSslErrors, Int32 retryCount, Int32 retryMinutes)
Jesse
January 6, 2016, 11:21pm
19
Show all of your settings again. all of them.
Its saying Addresses which is typically the CC email.
marios
January 6, 2016, 11:25pm
20
For now i think that the error is Samba’s internal and not Google’s