We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you a podcast all about Citrix Workspace, moving to the cloud, and analytics & intelligence. Episode 2 coming soon!Listen Now


Filemaker and Sending Mails

Cruizectrl asked
Medium Priority
Last Modified: 2012-05-05
I've been working on sending mails through filemaker and I have a good portion of it completed but now I've hit a brick wall and I'm realizing more and more that I'll have to do this through a "Send Event" to a VB Script.

The things that I want to do that isn't supported by the internal functions is send a mail "From" a certain account by populating the from field the mail message.

Sending the message automaticly is rather annoying since the security set on 2003 halts access for 5 seconds till you can okay it.

I guess I'll have to let the script pull record information to fill out the TO: and the message body.

And now that I'm trying to persue my issue in this direction I'm a noobie when it comes to VBScripting so I'm hoping someone has the solution at hand and its not going to be too painful.  If not, maybe there are some other avenues to explore.  

500 points because I know this is going to be brutal
Watch Question

>The things that I want to do that isn't supported by the internal functions is send a mail
>"From" a certain account by populating the from field the mail message.

Hmm, depending on how you're actually sending email from your network, this might be a whole lot easier than you think.

How does this email need to be generated? Does it need to be created on a client workstation using their default email client? Or would it be ok to bypass the client and send the message right to your SMTP server?

How are you sending outgoing email now? Do you have your own SMTP server?

If you have your own internal server, or if your ISP will cooperate, things may be a lot easier, as you can simply issue SMTP commands right to the server itself to generate the email. Here's a spiffy utility for doing this.

The requirement is, your SMTP server must be configured to allow relaying from the server or workstation where FileMaker is running. Important warning: You do NOT want to just enable relaying in general, That's a guaranteed way to get hammered by spammers and maybe get your internet service terminated. You need to ensure relaying is only allowed for that specific machine or group of machines.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts


Network with a SBS2003/Exchange server so from what your saying, I should be set up to use this utility.  But how do I pull the information I need to incorporate into the email from  fields in the database?  I hear you about the relay thing, I got slammed on that once already.

The database is stored on another applications server with filemaker network turned on with 5 people plugged in on the clients end.  Still should work right?
Yes, the "from" can't be setup from filemaker, since it uses the default mail client and account of the current logged user.
The utility Bill mentions is a way you can use if no mac is involved as client. Ideally, you should place the utility in a path which is true for every client, and this maybe difficult to achieve if the database is shared by a server.
The other way is to use a SMTP plug-in which allows complete control of email build up and sending, without using local account stuff.
2 mains one: CMS SMTPit (or pro) and DACONS mail.it
I prefer the CNS one, but DACONS gives a bit more for the same price, it does SMTP and POP3.
These things will make you work more that bmail, but the result is a lot better: you can send directly, in real time from within filemaker, using any field for all email parts, to, cc, cci, body, header, footer, inline images, formatted text to html or inline images. Thay have demo versions and example files, give it a try 15mn maybe


Back to the BMail.. I got the utility but for some reason its not opening an SMTP connection.

I set up a relay on the SMTP connect in the exchange manager to allow our domain relay access but it just keeps doing this.

C:\tools>bmail -s -t Apech@hegele-logistic.com -f Hub
babubba@hegele-logistic.com -b "test test test" -a "test" -d

Command Line SMTP Emailer V1.07
Copyright(C) 2002-2004 Craig.Peacock@beyondlogic.org
Opening connection to [] on port 25
Socket Closed

Am I doing something wrong?

the syntax is correct, therefore it is a pb with port25 not being open either on yr PC or on yr server.
try provider's SMTP direct maybe?


Commented: is our mail server.  I have no other provider.  Is there a way to look up what port SMTP is using if its been changed?

probably in exchange setup, but I have no experience with it, so can't tell you exactly where that lies.
check which port you use in any outlook account, it must be the same.
It's farily unlikely the SMTP port on the server has been changed, though it's possible.

More likely is that something on your LAN, or even workstation itself, is blocking SMTP. SMTP directly from the workstation is often blocked by ISPs and internet security suite/antivirus packages, because some viruses try to send email this way in order to spread themselves. Make sure there's nothing blocking port 25, either on your workstation, the server, or somewhere on the LAN (firewall, gateway, etc.)

If you want to rule out a problem with the bmail program itself, you can test your ability to connect to the SMTP server directly using TELNET. From a command prompt, type
You should get a brief prompt. After the prompt, type HELO or EHLO and hit enter to see a short message from the SMTP server. If this doesn't work, then bmail won't work either.



Didn't work.  I guess I'll have to take this question to another section eh?  There are some entries set in the relay section of SMTP in the exchange system manager.  Could this have something to do with it?  Do you know how I look up the true address?

if yr outlook can send an email, there is no reason why bmail can't...


I know right?  maybe its another port.
I can't help with your Exchange configuration, cuz I'm not an Exchange user. But it is possible that you could send via Outlook and still have trouble with sending via SMTP.

You might find some useful information here..
I've posted a pointer question to this one in the Exchange area, maybe one of the Exchange gurus over there can help with this.

no, outlook or any other smtp client is the same, they use the unique smpt port of their server.... so outlook does not use a different smtp port.
but yr company security, if you use exchange to setup domain rights, can allow only certain apps to use certain ports, so you may have to allow an extra process to use port 25 on the given workstation; try to disable the security center of yr PC (if you are enabled to do it) to see if it fixes it.
And good luck, because using exchange server to setup network rights is a lot of fun!


please check the following in exchange system manager smtp virtual server properties

Access Control MUST be All except the list below. It cannot be anything else otherwise you don't get email.
Relay should be ONLY the list below, and no IP address should be listed. If you don't have any SMTP clients like Outlook Express then you can disable the Users who authenticate setting as well.
if you have an SMTP Connector on the server, ensure that it isn't set to address space of * with the option to allow relaying to these domains disabled.

if these are ok then see the following
do u create a user and mailbox on exchange?
are u being able to send an email from outlook?

if u can then it might be security settings which are preventing please check the following

u can do the following to prevent security settings
If you need to share files that have file types blocked by this feature, you have several options, including the following:

Rename the files to include a temporary file type that is not on the list of blocked file types. For example, you might rename MyFile.exe to MyFile.exe_EXTRA, and then attach the file to the e-mail message. You can include instructions in the message to save the file with the correct name, for example, MyFile.exe, when the recipients save the file to their computers.
Use a program, such as WinZip, to package files before you attach them to your e-mail message. In your message, you can include instructions explaining how to extract the files from the package to make it easy for recipients to access the files.
>so outlook does not use a different smtp port.
Outlook doesn't have to use SMTP at all to talk to Exchange, it can talk directly to Exchange using MAPI, so you can't assume that Outlook working means that SMTP is working. Unless you're really talking about Outlook Express, it's unlikely that you're using SMTP to talk to Exchange.



I'm using Outlook 2003 and there are no problems sending and recieving from an exchange server.  You mentioned something about an SMTP connector.  Where is that located?



It was my Mcafee all along!  I keep forgeting that I have it there.  So I just went in and added Bmail.exe to the port 25 approval list and BANG!  all is well.

Splitting points

Thanks guys!

personal firewalls! what is that good to when you have a company one?
if you have a good reason to have one, this is the 1st thing to disable when a port can't be used.
and don't forget you'll have the same pb if you share filemaker files on yr PC: enable port 5003 first!
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.


Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.