Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Outlook / Programming VBA / June 2005

Tip: Looking for answers? Try searching our database.

Posting in a public folder / changing sender name.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
David. - 28 Jun 2005 15:37 GMT
Hi.

I'm using this code to post Item in the current folder , and i have 2
questions.

   Dim olPost As Outlook.PostItem
     
   Set olPost = ActiveExplorer.CurrentFolder.Items.Add("IPM.Post")
   
   olPost.BodyFormat = olFormatHTML
   olPost.HTMLBody = UserForm1.TextBox1.Value
   olPost.Subject = title
   olPost.UnRead = True
   olPost.Save
   olPost.Post
   Set olPost = Nothing

1: How can i change the sender name.
The default user profile is used, and i would like to change only the name.

2:Can i specified another folder instead of use the current folder and then
item.move to the specific folder.

Thanks.
Eric Legault [MVP - Outlook] - 28 Jun 2005 20:40 GMT
The SenderName property is read-only, and resolves to the display name of the
user for the e-mail account or Exchange profile that is being used to post an
item or send an e-mail.

You can set the SentOnBehalfOfName property, but this must resolve to an
entry in your Exchange Global Address List, AND you need to have been
delegated Send As rights for that mailbox.

Another alternative is to create a new message with a different originator,
but this requires CDO:

http://www.cdolive.com/cdo5.htm#MessageOriginator

If you want to post your item to another folder other than the current one,
you'll have to set an explicit reference to the MAPIFolder object for that
folder by walking the NameSpace.Folders collection:

e.g.

Set myFolder = objNS.Folders.Item("Mailbox - jdoe")
Set myInBox = myFolder.Folders("Inbox")
Set myInboxSubFolder = myInbox.Folders("Stuff")
etc.

Note that you don't need to call the Move method, but just call the
Items.Add event for the folder that you obtained as above.

Signature

Eric Legault - B.A, MCP, MCSD, Outlook MVP
Try Picture Attachments Wizard for Outlook! http://tinyurl.com/9bby8
Job: http://www.imaginets.com
Blog: http://blogs.officezealot.com/legault/

> Hi.
>
[quoted text clipped - 20 lines]
>
> Thanks.
David. - 29 Jun 2005 10:52 GMT
Thanks for your help.

But i need more informations.

1st:
I don't want to set a real name of a sender, and i don't have Exchange.
It's a stand alone Outlook.
My goal is just to set a string in that field not a real sender name.
I know it can be done, because some "plugin" do it, but the question is how?!

2nd:CDO is a CNT extension, and i'm not familliar with Outlook
developpement, so i don't have a clue , to what i have to do with this? (to
put it on a exchange server?)

Thanks again for your support.

David

> The SenderName property is read-only, and resolves to the display name of the
> user for the e-mail account or Exchange profile that is being used to post an
[quoted text clipped - 47 lines]
> >
> > Thanks.
Eric Legault [MVP - Outlook] - 29 Jun 2005 15:35 GMT
You say you don't have Exchange, but you're using a Public Folder??

AFAIK, you cannot alter the sender name to be different than the user
name/address properties that are defined for the account that the e-mail is
being sent through, aside from using delegation.

What do you mean by "CNT extension"?

If you want to program with the CDO library, this is an optional install
during Office setup.  More info on programming with CDO are at these links:

http://www.cdolive.com
Using Collaboration Data Objects (CDO) in Microsoft Outlook and Microsoft
Exchange Programming: http://www.outlookcode.com/d/cdo.htm

Signature

Eric Legault - B.A, MCP, MCSD, Outlook MVP
Try Picture Attachments Wizard for Outlook! http://tinyurl.com/ckytm
Job: http://www.imaginets.com
Blog: http://blogs.officezealot.com/legault/

> Thanks for your help.
>
[quoted text clipped - 65 lines]
> > >
> > > Thanks.
David. - 29 Jun 2005 17:25 GMT
You are once again right.
It's not a "Public Folder", It's just a "simple" folder on my outlook.
I used a wrong terminology.

So, in fact, i just want to create a IPM in a folder with a specific
"Sender" name.

I will take a look in the CDO web site as soon as i understand how to
install it.
So far i did not find in the FAQ.

Best regards and thanks again .

> You say you don't have Exchange, but you're using a Public Folder??
>
[quoted text clipped - 80 lines]
> > > >
> > > > Thanks.
Eric Legault [MVP - Outlook] - 29 Jun 2005 17:47 GMT
To install CDO, run Office setup, choose a custom installation, and select
Collaboration Data Objects in the list of optional Outlook components.

Signature

Eric Legault - B.A, MCP, MCSD, Outlook MVP
Try Picture Attachments Wizard for Outlook! http://tinyurl.com/ckytm
Job: http://www.imaginets.com
Blog: http://blogs.officezealot.com/legault/

> You are once again right.
> It's not a "Public Folder", It's just a "simple" folder on my outlook.
[quoted text clipped - 93 lines]
> > > > >
> > > > > Thanks.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.