Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DoCmd.SendObject format question.

Status
Not open for further replies.

MkIIISupra

Programmer
Apr 17, 2002
108
US
Below is the code I have at the moment (still in the creating phase...) anyhow what I would like to do is set the code to format the e-mail for me. What I mean is simple. Below this code chunk is test output from the code below as it is formatted and sent. Below that is what I would like it to look like when the user pushes the button.
Code:
DoCmd.SendObject , , , "user@user.com", , Me.copyTo, "Print Request", "DATE REQUESTED: " & Me.dateReq _
          & "   TIME REQUESTED: " & Me.timeReq & "    TRACKING NO: " & Me.trkNum & vbCrLf & "REQUESTOR: " _
          & Me.requestor & "    TEAM NO: " & Me.tmNum & "    PHONE NO: " & Me.reqPhNum & vbCrLf _
          & "CUSTOMER: " & Me.custId & "    ST: " & Me.state & vbCrLf & Me.reptReason, True

DATE REQUESTED: 5/11/2006 TIME REQUESTED: 1:52:33 PM TRACKING NO: 123435213-08
REQUESTOR: some user TEAM NO: 6 PHONE NO: XXX-XXX-XXXX
CUSTOMER: diocese of burlingon ST: vt
RERUN


DATE REQUESTED: 5/11/2006 TIME REQUESTED: 1:52:33 PM TRACKING NO: 123435213-08
REQUESTOR: some user TEAM NO: 6 PHONE NO: XXX-XXX-XXXX
CUSTOMER: diocese of township ST: wa
RERUN:

So can I set the BOLD and UNDERLINE attributes in VBA and if so how do I do that? I have been looking but it seems that I am not finding...

Again as always Thank you for your time and answers!

One by one the penguins return my sanity, as day by day Microsoft steals my sanity!

OpenSuSE 10.0 kicks fanny!
 
I do not think you can do this with SendObject. I think you will need to use Outlook, for example, and .HTMLBody or Rich Text. Alterantively, you might try a Word (e-)mailmerge.
 
Can't use either due to the fact this is a form to replace an Outlook form from 2000. The problem is we had someone build a form for sending print requests in a preformatted method via Outlook. Worked great in 2000, but now that we have moved to Outlook 2003 the form no longer works. So I have been tasked to create an Access for that does the same thing BUT the caveat is no matter which version of office we run it will be backwards and forwards compatible.

It's not critical that I can do this, I was just hoping I could. I have a solution though that I am going to test and that is to have dummy fields with this data pre-formatted and insert that and see if it will work. I'll let you know if it does or not... Thanks!

One by one the penguins return my sanity, as day by day Microsoft steals my sanity!

OpenSuSE 10.0 kicks fanny!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top