Send Excel form VIA Email

S

Sam

I have an Excel form that has a submit button and this button should
open up a MS Outlook email attach the form and past the value from
cell R13 in to the subject. Is there code that will do this? If, so
what would it be? I tried the little I know but could not get it to
work.

Thanks
Sam
 
R

Ron de Bruin

You can test it like this

Sub test()
If WorksheetFunction.CountA(Range("B5, J5")) = 2 Then
'Run your mail code
Else
MsgBox "Please fill in B5 and J5"
End If
End Sub


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


Oops

This is a example for one sheethttp://www.rondebruin.nl/mail/folder1/mail2.htm

--

Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm






- Show quoted text -

This worked great. Is there a way to check to see if certian
conditions are met. For example do not run unless Cell B5 & J5 are
populated>

Thanks for your help!!!!!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top