Can you try this
grant execute on xp_smtp_sendmail to public --give exec to public instead of Sysadmin.
Main Topics
Browse All TopicsI was using XPSMTP80.DLL to acheive this task. I register the dll into the bin folder of Microsoft SQL and then in the master database did the following
exec sp_addextendedproc 'xp_smtp_sendmail', 'xpsmtp80.dll'
grant execute on xp_smtp_sendmail to sysadmin
when i run my stored proc it gives me an error:
ODBC: Msg 0, Level 16, State 1 Cannot load the DLL xpsmtp80.dll, or one of the DLLs it references. Reason: 126(The specified module could not be found.).
Please help. thanks.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
right, you have to do a bit of config to get xp_sendmail to work. read this:
http://support.microsoft.c
The following is taken from:
http://gregs.tcias.co.uk/d
"
In order to use this DLL and the stored procedures associated it with it, you'll need to first register it and then assign it the right execute permissions. Below are the steps required as found on the aforementioned web site.
-- SQL Server 2000 install
exec sp_addextendedproc 'xp_smtp_sendmail', 'xpsmtp80.dll'
-- give execute permissions
grant execute on xp_smtp_sendmail to public
"
It appears to me that you granted executed permissions to the sysadmin role. Are you sure that the user account connected to QA when calling the procedure is in the sysadmin role? Try granting execute permission explicity to the user account that will be aclling the program. Additionally, check to be sure that the security permissions on the BINN folder allow accessibility for the user account in question.
try to use full path to the file xpsmtp80.dll:
for example:
exec sp_addextendedproc 'xp_smtp_sendmail', 'C:\Program Files\Microsoft SQL Server\MSSQL\Binn\xpsmtp80
more info @:
http://www.sqldev.net/xp/x
Business Accounts
Answer for Membership
by: SweatCoderPosted on 2006-10-16 at 11:52:48ID: 17741427
I'm not sure, but have you considered using mssql's built-in xp_sendmail?
EXEC master..xp_sendmail
@recipients = 'somebody@somewhere.com',
@subject = 'hello',
@message = 'hello world'