PC Review


Reply
Thread Tools Rate Thread

Assign "From" line with VB script?

 
 
New Member
Join Date: Aug 2010
Posts: 2
 
      13th Aug 2010
Hi,

I am attempting to use VB to assign the, "From" line or sending address for an email in a merge project from Excel.

What I have attemted to use is below, but that resulted in an, "Object not supported error".



OlMail.Recipients.Add Email
With OlMail
.CC = EmailCC
.BCC = EmailBCC
.Attachments.Add (Attachment)

.From = From
End With


The String variable, "From" is assigned with the following code, refrencing an excel cell.

From = ActiveCell.Offset(0, 8)


Please forgive me if this is a newbie error, my primary programing experience is with Applesoft Basic.

Is the "FROM" line even an addressable object in Outlook with VB? Im certian that it is as we have outlook add-ins that do this for us based on the folder tree user is in. However im not sure what language they are using to assign it.

Any assistance will be met with a nice tasty present of Tab cola and hotpockets.

Oh, and it's Outlook 2007 SP2 y'all.

Thakns,
Tim
 
Reply With Quote
 
 
 
 
New Member
llyon29358's Avatar
Join Date: Aug 2010
Posts: 5
 
      8th Sep 2010
If you have not figured this out by now, try .SenderName
 
Reply With Quote
 
New Member
Join Date: Aug 2010
Posts: 2
 
      9th Sep 2010
Thanks for your reply, and my appoligies for not updating my post when I found the solution. The correct item in my case was ".sendonbehalfof"

These are additional exchange accounts that our domain accounts have rights to send mail as.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Printers and Faxes", command line or script to open? Trygve Lorentzen Windows XP General 5 20th Mar 2007 11:03 AM
<FORM METHOD="post" onSubmit="return fieldcheck()" name="orientation" action="http://ws-kitty.BU.edu/AT/survey/orientation/script/write.asp" language="JavaScript"> Joeyej Microsoft ASP .NET 0 4th Jun 2004 08:55 PM
How I can launch "Local Area Connection Properties" Page directly from command line or a script =?Utf-8?B?QW5hbmQ=?= Windows XP Setup 0 23rd Feb 2004 03:46 PM
how to assign a "hot-key" or "Macro" to Word "strikethough" feature =?Utf-8?B?TWlrZQ==?= Microsoft Word Document Management 3 5th Dec 2003 10:24 PM
How to "Log Off" from command-line (from batch script)? John Windows XP Setup 2 1st Jul 2003 06:11 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:49 PM.