1

I'm sending a generic email when records get uploaded to a sql table. My issue is that the font of the email being sent is green. How do I change that? And Where?

Here is my code:

DECLARE @MyRecipients varchar(max) 
SET @MyRecipients =  
STUFF((SELECT ';' + email       
FROM dbo.Expense_Projection         
WHERE StatusID = 1 and dbo.Expense_Projection.StatusDate = '2015-10-21' 
FOR XML PATH('')),1,1,'') 
Print @MyRecipients 
exec msdb.dbo.sp_send_dbmail      
    @profile_name = 'Travel NoReply Profile',     
    @subject = 'Professional Development Travel Funds Are Now Allocated', 
    @body = 'Thank you for applying for Travel funds. ',     
    @body_format = 'HTML',     
    @recipients = @MyRecipients ,     
    @copy_recipients = '',     
    @blind_copy_recipients = ''      
Andy Hunn
  • 21
  • 2
  • 7

1 Answers1

1

This is obviously too late to help you but might help someone else, since I was looking for such an answer when I found this question. When I needed to do this with an email whose @body_format = 'HTML' like yours, I enclosed the value for the @body text in a span and added style attributes to it:

@body = '<span style="color:#990000; font-weight:bold;">Thank you for applying for travel funds.</span> ', 
wildcatter
  • 11
  • 2