Tom.......that pesky E-mail thingy
Posted by Ian on September 05, 2001 1:37 AM
Thought I'd start again up here:
I can't seem to get this to work, I've completely messed things around but nothing. As you'll see nothing is in the right place, perhaps I should have said that I'm pretty crap at this stuff.
Couldn't workout what you ment by placing something after the With thing, what With thing.
help would be fantastic, cheers Ian
Private Sub CommandButton1_Click()
Dim OLook As Object 'Outlook.Application
Dim Mitem As Object 'Outlook.Mailitem
Dim SendAnEmail As Boolean
Dim fname As Object
Dim otlAttach As Object
Set OLook = CreateObject("Outlook.Application")
Set Mitem = OLook.createitem(0)
Set fname = ActiveWorkbook.Path & "\" & ActiveWorkbook.Name
Mitem.to = "firstname.lastname@example.org"
Mitem.Subject = "Here's the figure's for the week commencing " _
& Cells(4, 2).Value
Mitem.body = "hello"
Set otlAttach = Nothing