andrewb90
Well-known Member
- Joined
- Dec 16, 2009
- Messages
- 1,077
hello all,
I have been using VBA to send emails out to a set email address and corresponding password, however I need to reference a cell so that it can be changed as needed. I'm hoping I just made a little error...
This is the original:
Here is what I tried to do:
I have been using VBA to send emails out to a set email address and corresponding password, however I need to reference a cell so that it can be changed as needed. I'm hoping I just made a little error...
This is the original:
Code:
sTo = Right(sTo, Len(sTo) - 1) Gmail "email@gmail.com", "password", "" _
, "o> " _
& vbNewLine & Sheets("Print").Range("D1")
Here is what I tried to do:
Code:
sTo = Right(sTo, Len(sTo) - 1) Gmail "Sheets("Home").Range("P16")", "Sheets("Home").Range("P18")", "" _
, "o> " _
& vbNewLine & Sheets("Print").Range("D1") _