PC Review


Reply
Thread Tools Rate Thread

Re: The sender problems, help me pls?

 
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      6th Jan 2009
UseMailItem.SendUsingAccount property (Outlook 2007 specific).

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:8fc5a50ffeeda@uwe...
> My first problem is fixed, save the item, the getprops, it is ok. The
> error i
> said before is caused by other reason.
> Then, how about my second problem? Thx very much.
>
> --
> Message posted via OfficeKB.com
> http://www.officekb.com/Uwe/Forums.a...ddins/200901/1
>



 
Reply With Quote
 
 
 
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      8th Jan 2009
You can set these properties using Extended MAPI (shouldn't be a problem if
you are using C++) - IMessage interface can be obtained through the
MailItem.MAPIOBJECT property. To retrieve the accoutn naame and id, use the
IOlkAccountManager interface.

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:8fd0a5122dad4@uwe...
> Thank you Dmitry, but how about outlook2003, the main task of our product
> should be implemented on 2003 not 2007.(I known outlook2007 have some new
> interfaces and structruces can do the job easily).
>
> Dmitry Streblechenko wrote:
>>UseMailItem.SendUsingAccount property (Outlook 2007 specific).

>
> --
> Message posted via OfficeKB.com
> http://www.officekb.com/Uwe/Forums.a...ddins/200901/1
>



 
Reply With Quote
 
 
 
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      9th Jan 2009
The first account in the list returned by IOlkAccountManager::GetOrder
method is teh default one.
You can play with IOlkAccountManager in OutlookSpy - click Misc |
IOlkAccountManager.

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:8fdf87823e701@uwe...
> That's great, i will try it tommorrow. How can i use this interface to set
> the account to send email? I find a sample on codeproject.com. It can
> retrieve all accounts, but how to set the default account, the SetOrder()
> function? But how could i know which one is the current default account?
> Thanks very much.
>
> Dmitry Streblechenko wrote:
>>You can set these properties using Extended MAPI (shouldn't be a problem
>>if
>>you are using C++) - IMessage interface can be obtained through the
>>MailItem.MAPIOBJECT property. To retrieve the accoutn naame and id, use
>>the
>>IOlkAccountManager interface.
>>

>
> --
> Message posted via OfficeKB.com
> http://www.officekb.com/Uwe/Forums.a...ddins/200901/1
>



 
Reply With Quote
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      9th Jan 2009
Do not reset the default account, simply set the appropriate named
properties on the message to tell Outlook which account it should use for
sending.

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:8feb53939ec5d@uwe...
> Thank you Dmitry, the IOlkAccountManager can Set the default account, but
> i
> still have question here.
> Say A is the default account, B is another, and C send a message to B. B
> should auto reply a message to C.
> This is my code flow for repy message to C:
> 1. Set specified account(B) as default.(SetOrder)
> 2. Create the message and send it.
> 3. Restore the original account(A).(SetOrder again)
> well, the problem is that How could i known when the message is already
> sent.
> The result of my code is alway send by A. If i mark the 3. It can
> work(send
> by B). But it is bad for that change the default account and user may
> don't
> know that, right?
> In one word, when should i do the action 3?
> Thanks in advance.
>
> Dmitry Streblechenko wrote:
>>The first account in the list returned by IOlkAccountManager::GetOrder
>>method is teh default one.
>>You can play with IOlkAccountManager in OutlookSpy - click Misc |
>>IOlkAccountManager.
>>

>
> --
> Message posted via OfficeKB.com
> http://www.officekb.com/Uwe/Forums.a...ddins/200901/1
>



 
Reply With Quote
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      12th Jan 2009
How exactly do you send the message?
Are you sure you set these properties correctly? Did you compare the values
to the messages sent through through teh UI?

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:9002741789ae6@uwe...
> Could you pls tell me which properties i should use. CurrentItem-
>>SendOnBehalfOfName(Exchange only)can't work, mine is POP3/SMTP. Also I

> change the IMessage's 0x8013 InetAcctID and InetAcctName manually, it
> still
> use the default account to send my mail. The PR_SENDEMAIL_ADDRESS,
> PR_SENDEMAILNAME can't work at all. And I can't find PR_PRESENTING_XXXX in
> IMessage via outlookspy.
>
> Dmitry Streblechenko wrote:
>>Do not reset the default account, simply set the appropriate named
>>properties on the message to tell Outlook which account it should use for
>>sending.
>>

>
> --
> Message posted via OfficeKB.com
> http://www.officekb.com/Uwe/Forums.a...ddins/200901/1
>



 
Reply With Quote
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      13th Jan 2009
You are posting through officekb.com, not direcly to the Microsoft server.
I saw your reply just fine, but I don't think you answered my questions:

1. How exactly do you send the message?
2. Are you sure you set these properties correctly? Did you compare the
values to the messages sent through through the UI? I mean the message
properties that hold the account name and id, not the
PR_SENT_REPRESENTING_XXX properties.


--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:901b18c3d6ad3@uwe...
> oh, no, Should this be a bug for this discuss forum? I posted a reply, but
> when you are in reply action, you can't see it. After you click post
> button,
> you can see the reply i were posted.
> ////////////////////////////This is what i posted last
> time//////////////////////////////
> Hi, Dmitry. I have successfully set the PR_SENT_REPRESENTING_XXX. Say,
> Outlook have two accounts, http://www.pcreview.co.uk/forums/(E-Mail Removed)(default), (E-Mail Removed). Then
> ccc@ccc.
> com send a message to (E-Mail Removed). ok, my code generate a message, and
> sent
> it to (E-Mail Removed). But it is strange that the message (E-Mail Removed) received
> is
> something like(you should open the mail by double click the message):
> FROM: (E-Mail Removed) representing (E-Mail Removed)
> TO: (E-Mail Removed)
>
> But the item in folder show that the sender is (E-Mail Removed).
> So actually, the message is send by the default account (E-Mail Removed). What
> should i do to use (E-Mail Removed) send the mail? Or just change "FROM:
> aaa@aaa.
> com representing (E-Mail Removed)" to "(E-Mail Removed)."
> ////////////////////////////////////////////////Last posted
> end//////////////////////////////////
> As i mentioned in this post, and i check the message while receive it. The
> PR_SENT_REPRESENTING_XXX is currently set.
> My questiones are:
> 1. What should i do to use (E-Mail Removed) send the mail?
> 2. Or just change "FROM: (E-Mail Removed) representing (E-Mail Removed)" to
> "bbb@bbb.
> com."
>
>
> Dmitry Streblechenko wrote:
>>How exactly do you send the message?
>>Are you sure you set these properties correctly? Did you compare the
>>values
>>to the messages sent through through teh UI?
>>
>>> Could you pls tell me which properties i should use. CurrentItem-
>>>>SendOnBehalfOfName(Exchange only)can't work, mine is POP3/SMTP. Also I

>>[quoted text clipped - 7 lines]
>>>>properties on the message to tell Outlook which account it should use
>>>>for
>>>>sending.

>
> --
> Message posted via http://www.officekb.com
>



 
Reply With Quote
 
Dmitry Streblechenko
Guest
Posts: n/a
 
      14th Jan 2009
After you set these two properties, does Outlook display the right account
when you open the message?
Youy are sending through SMTP, not Exchange, right?

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"ryotyankou via OfficeKB.com" <u48591@uwe> wrote in message
news:9028cee28a518@uwe...
>I noticed that if i choose sender by click droplist and then save the
>message.
> Just two properties is changed obviously. Do you mean the two properties?
> In
> fact, i tried these two before, but i didn't know how to set them, i
> search
> through the network, but found too few to use. Can you help me for that
> how
> can i do deal with this? Any tips or links will ok. Thank you in advance.
>
>>2. Are you sure you set these properties correctly? Did you compare the
>>values to the messages sent through through the UI? I mean the message
>>properties that hold the account name and id, not the
>>PR_SENT_REPRESENTING_XXX properties.
>>

>
> --
> Message posted via http://www.officekb.com
>



 
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
Help! Help! Help! Help! Help! Help! Help! Help! Help! Help! Help! Help! Help! -$- Windows XP Internet Explorer 2 21st Dec 2003 11:45 PM
HOT KEY for adding sender to blocked sender list in Outlook 2003? BoDEAN Microsoft Outlook 2 22nd Oct 2003 06:14 PM
HOT Key for adding sender to blocked sender list in Outlook 2003? BoDEAN Microsoft Outlook Discussion 0 22nd Oct 2003 01:30 PM
Block Sender's not blocking sender Susan Microsoft Outlook Discussion 0 19th Oct 2003 05:14 AM
Send email w/o sender's info i.e. sender's email address Alex Microsoft Outlook Discussion 1 14th Jul 2003 01:07 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:55 PM.