RE:The signature is also inserted if you touch the MailItem.

Status
Not open for further replies.
G

Gunjan

Hi Dmitry,

Can you please explain in detail how to touch MailItem.GetInspector property?

Regards,

Gunjan

Dmitry Streblechenko wrote:

The signature is also inserted if you touch the MailItem.

24-Oct-07

The signature is also inserted if you touch the MailItem.GetInspector

property for the brand new messages with unmodified body. You do not need to

actually display the message. This is probably the easiest way to insert the

signature if you do not want to display the item first.

Dmitry Streblechenko (MVP)

"Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message

news:uyNUvIoFIHA.1212@TK2MSFTNGP05.phx.gbl...

It does, if (a) the user has an automatic signature set up and (b) you call

MailItem.Display first.

Sue Mosher

"Jeff" <budajeff@gmail.com> wrote in message

news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

Previous Posts In This Thread:

On Wednesday, October 24, 2007 11:27 AM

Jeff wrote:

Email signature using Outlook COM object model

Can someone confirm that the Outlook 2003 COM object model does not

provide a way to programmatically get, modify, or remove the signature

line of an email?

Furthermore, it doesn't look like Redemption RDO supports manipulating

the signature line either (http://www.google.com/search?q=signature

+site%3Ahttp%3A%2F%2Fwww.dimastr.com%2Fredemption

%2F&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-

US:eek:fficial&client=firefox-a).

I've noticed that a SafeMailItem will contain the signature line as

long as I don't modify the Body property. Has anyone else noticed

that?

Thanks,

Jeff

On Wednesday, October 24, 2007 11:31 AM

Sue Mosher [MVP-Outlook] wrote:

It certainly is possible to add a signature to an email message.

It certainly is possible to add a signature to an email message. If Word =

is the editor, it's also easy to remove it, because it's exposed as a =

Bookmark object. See =

http://www.outlookcode.com/codedetail.aspx?id=3D615. If Word is not the =

email editor, the signature is not distinguished in any way from the =

rest of the text.

--

Sue Mosher

http://www.outlookcode.com/article.aspx?id=3D54

"Jeff" <budajeff@gmail.com> wrote in message =

news:1193239651.709913.105960@v23g2000prn.googlegroups.com...

On Wednesday, October 24, 2007 12:03 PM

Jeff wrote:

Thanks for the link.

Thanks for the link.

I did not see the text of the signature in the value of the Body

property of Redemption's SafeMailItem, as one might expect. Based on

that test, also I assume that the signature would not appear in

RDO.RDOMail.Body, .HTMLBody, .RTFBody either, but I didn't take the

time to test those. I didn't see a ".Signature" property or equivalent

in Outlook COM, Redemption Safe* items, or Redemption RDO objects. Am

I missing something?

In my install of Outlook 2003 (Word as Editor, HTML format by

default) the signature line is getting added as long as I don't

manipulate the SafeMailItem.Body property. Is that expected?

Thanks,

Jeff

On Wednesday, October 24, 2007 1:22 PM

Sue Mosher [MVP-Outlook] wrote:

There is no Signature property.

There is no Signature property. The operations I describe do not depend =

on there being one.

It might help if you showed some code. Without that, we have no way of =

knowing in what order you're performing operations, etc. If you =

overwrite the Body property, for example, any signature that already =

exists is going to be replaced by your new Body text.

--

Sue Mosher

http://www.outlookcode.com/article.aspx?id=3D54

"Jeff" <budajeff@gmail.com> wrote in message =

news:1193241830.322984.25360@k35g2000prh.googlegroups.com...

"Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message =

news:eBVfEMlFIHA.3672@TK2MSFTNGP02.phx.gbl...

It certainly is possible to add a signature to an email message. If Word =

is the editor, it's also easy to remove it, because it's exposed as a =

Bookmark object. See =

http://www.outlookcode.com/codedetail.aspx?id=3D615. If Word is not the =

email editor, the signature is not distinguished in any way from the =

rest of the text.

"Jeff" <budajeff@gmail.com> wrote in message =

news:1193239651.709913.105960@v23g2000prn.googlegroups.com...

On Wednesday, October 24, 2007 2:46 PM

Jeff wrote:

You've provided some great ideas on how to work w/ the signature, andI

You've provided some great ideas on how to work w/ the signature, and

I appreciate them. I'm just trying to focus in on what the Outlook COM

object model alone provides.

For a new email, if setting MailItem.Body erases the signature line of

an email, then one would hope that getting MailItem.Body prior to

setting it would retrieve the signature line of an email.

It'd be nice to be able to do something like this:

pseudocode snippet:

//create a new mail item

MailItem m = folder.Item.Add(OlItemType.olMailItem);

//store off the signature line (if the user has the option on):

String sig = m.Body;

//set Body to be my email content plus whatever the signature line is

m.Body = "my email content" + sig;

Contrary to how I'd like MailItem.Body to work, getting it prior to

setting it returns nothing (even if there is a signature line), and

setting it to something removes the signature line. I see no way to

set the Body of the email to my email content while at the same time

maintaining whatever signature line the user specified to appear in

new emails by default.

Thanks for your patience.

jb

On Wednesday, October 24, 2007 5:09 PM

Sue Mosher [MVP-Outlook] wrote:

It does, if (a) the user has an automatic signature set up and (b) you =call

It does, if (a) the user has an automatic signature set up and (b) you =

call MailItem.Display first.

--

Sue Mosher

http://www.outlookcode.com/article.aspx?id=3D54

"Jeff" <budajeff@gmail.com> wrote in message =

news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

On Wednesday, October 24, 2007 6:24 PM

Dmitry Streblechenko wrote:

The signature is also inserted if you touch the MailItem.

The signature is also inserted if you touch the MailItem.GetInspector

property for the brand new messages with unmodified body. You do not need to

actually display the message. This is probably the easiest way to insert the

signature if you do not want to display the item first.

Dmitry Streblechenko (MVP)

"Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message

news:uyNUvIoFIHA.1212@TK2MSFTNGP05.phx.gbl...

It does, if (a) the user has an automatic signature set up and (b) you call

MailItem.Display first.

Sue Mosher

"Jeff" <budajeff@gmail.com> wrote in message

news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

On Thursday, October 25, 2007 7:57 AM

Sue Mosher [MVP-Outlook] wrote:

Good to know. Thanks!

Good to know. Thanks!

--

Sue Mosher

http://www.outlookcode.com/article.aspx?id=3D54

"Dmitry Streblechenko" <dmitry@dimastr.com> wrote in message =

news:O6P5wxoFIHA.4956@TK2MSFTNGP06.phx.gbl...

need to

insert the

call

COM

of

WPF Report Engine, Part 4

http://www.eggheadcafe.com/tutorial...45-8b37cb7f3186/wpf-report-engine-part-4.aspx
 
set DummyVariable = MailItem.GetInspector

is all it takes

Dmitry Streblechenko (MVP)

-

<Gunjan> wrote in message news:20104283837gunjsh@yahoo.co.in...
> Hi Dmitry,

> Can you please explain in detail how to touch MailItem.GetInspector
> property?

> Regards,
> Gunjan

> Dmitry Streblechenko wrote:

> The signature is also inserted if you touch the MailItem.
> 24-Oct-07

> The signature is also inserted if you touch the MailItem.GetInspector
> property for the brand new messages with unmodified body. You do not need
> to
> actually display the message. This is probably the easiest way to insert
> the
> signature if you do not want to display the item first.

> Dmitry Streblechenko (MVP)
>

>

> > "Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message
> news:uyNUvIoFIHA.1212@TK2MSFTNGP05.phx.gbl...

> It does, if (a) the user has an automatic signature set up and (b) you
> call
> MailItem.Display first.

> > Sue Mosher
> > >

> "Jeff" <budajeff@gmail.com> wrote in message
> news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

> Previous Posts In This Thread:

> On Wednesday, October 24, 2007 11:27 AM
> Jeff wrote:

> Email signature using Outlook COM object model
> Can someone confirm that the Outlook 2003 COM object model does not
> provide a way to programmatically get, modify, or remove the signature
> line of an email?

> Furthermore, it doesn't look like Redemption RDO supports manipulating
> the signature line either (http://www.google.com/search?q=signature
> +site%3Ahttp%3A%2F%2Fwww.dimastr.com%2Fredemption
> %2F&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:en-
> US:eek:fficial&client=firefox-a).

> I've noticed that a SafeMailItem will contain the signature line as
> long as I don't modify the Body property. Has anyone else noticed
> that?

> Thanks,
> Jeff

> On Wednesday, October 24, 2007 11:31 AM
> Sue Mosher [MVP-Outlook] wrote:

> It certainly is possible to add a signature to an email message.
> It certainly is possible to add a signature to an email message. If Word =
> is the editor, it's also easy to remove it, because it's exposed as a =
> Bookmark object. See =
> http://www.outlookcode.com/codedetail.aspx?id=3D615. If Word is not the =
> email editor, the signature is not distinguished in any way from the =
> rest of the text.

> --
> Sue Mosher
> > > http://www.outlookcode.com/article.aspx?id=3D54

> "Jeff" <budajeff@gmail.com> wrote in message =
> news:1193239651.709913.105960@v23g2000prn.googlegroups.com...

> On Wednesday, October 24, 2007 12:03 PM
> Jeff wrote:

> Thanks for the link.
> Thanks for the link.

> I did not see the text of the signature in the value of the Body
> property of Redemption's SafeMailItem, as one might expect. Based on
> that test, also I assume that the signature would not appear in
> RDO.RDOMail.Body, .HTMLBody, .RTFBody either, but I didn't take the
> time to test those. I didn't see a ".Signature" property or equivalent
> in Outlook COM, Redemption Safe* items, or Redemption RDO objects. Am
> I missing something?

> In my install of Outlook 2003 (Word as Editor, HTML format by
> default) the signature line is getting added as long as I don't
> manipulate the SafeMailItem.Body property. Is that expected?

> Thanks,
> Jeff

> On Wednesday, October 24, 2007 1:22 PM
> Sue Mosher [MVP-Outlook] wrote:

> There is no Signature property.
> There is no Signature property. The operations I describe do not depend =
> on there being one.

> It might help if you showed some code. Without that, we have no way of =
> knowing in what order you're performing operations, etc. If you =
> overwrite the Body property, for example, any signature that already =
> exists is going to be replaced by your new Body text.

> --
> Sue Mosher
> > > http://www.outlookcode.com/article.aspx?id=3D54

> "Jeff" <budajeff@gmail.com> wrote in message =
> news:1193241830.322984.25360@k35g2000prh.googlegroups.com...

> "Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message =
> news:eBVfEMlFIHA.3672@TK2MSFTNGP02.phx.gbl...
> It certainly is possible to add a signature to an email message. If Word =
> is the editor, it's also easy to remove it, because it's exposed as a =
> Bookmark object. See =
> http://www.outlookcode.com/codedetail.aspx?id=3D615. If Word is not the =
> email editor, the signature is not distinguished in any way from the =
> rest of the text.

> "Jeff" <budajeff@gmail.com> wrote in message =
> news:1193239651.709913.105960@v23g2000prn.googlegroups.com...

> On Wednesday, October 24, 2007 2:46 PM
> Jeff wrote:

> You've provided some great ideas on how to work w/ the signature, andI
> You've provided some great ideas on how to work w/ the signature, and
> I appreciate them. I'm just trying to focus in on what the Outlook COM
> object model alone provides.

> For a new email, if setting MailItem.Body erases the signature line of
> an email, then one would hope that getting MailItem.Body prior to
> setting it would retrieve the signature line of an email.

> It'd be nice to be able to do something like this:

> pseudocode snippet:

> //create a new mail item
> MailItem m = folder.Item.Add(OlItemType.olMailItem);

> //store off the signature line (if the user has the option on):
> String sig = m.Body;

> //set Body to be my email content plus whatever the signature line is
> m.Body = "my email content" + sig;

> Contrary to how I'd like MailItem.Body to work, getting it prior to
> setting it returns nothing (even if there is a signature line), and
> setting it to something removes the signature line. I see no way to
> set the Body of the email to my email content while at the same time
> maintaining whatever signature line the user specified to appear in
> new emails by default.

> Thanks for your patience.

> jb

> On Wednesday, October 24, 2007 5:09 PM
> Sue Mosher [MVP-Outlook] wrote:

> It does, if (a) the user has an automatic signature set up and (b) you
> =call
> It does, if (a) the user has an automatic signature set up and (b) you =
> call MailItem.Display first.

> --
> Sue Mosher
> > > http://www.outlookcode.com/article.aspx?id=3D54

> "Jeff" <budajeff@gmail.com> wrote in message =
> news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

> On Wednesday, October 24, 2007 6:24 PM
> Dmitry Streblechenko wrote:

> The signature is also inserted if you touch the MailItem.
> The signature is also inserted if you touch the MailItem.GetInspector
> property for the brand new messages with unmodified body. You do not need
> to
> actually display the message. This is probably the easiest way to insert
> the
> signature if you do not want to display the item first.

> Dmitry Streblechenko (MVP)
>

>

> > "Sue Mosher [MVP-Outlook]" <suemvp@outlookcode.com> wrote in message
> news:uyNUvIoFIHA.1212@TK2MSFTNGP05.phx.gbl...

> It does, if (a) the user has an automatic signature set up and (b) you
> call
> MailItem.Display first.

> > Sue Mosher
> > >

> "Jeff" <budajeff@gmail.com> wrote in message
> news:1193251617.973737.326100@q3g2000prf.googlegroups.com...

> On Thursday, October 25, 2007 7:57 AM
> Sue Mosher [MVP-Outlook] wrote:

> Good to know. Thanks!
> Good to know. Thanks!

> --
> Sue Mosher
> > > http://www.outlookcode.com/article.aspx?id=3D54

> "Dmitry Streblechenko" <dmitry@dimastr.com> wrote in message =
> news:O6P5wxoFIHA.4956@TK2MSFTNGP06.phx.gbl...
> need to
> insert the
> call
> COM
> of

> WPF Report Engine, Part 4
> http://www.eggheadcafe.com/tutorial...45-8b37cb7f3186/wpf-report-engine-part-4.aspx
 
Status
Not open for further replies.
Similar threads
Thread starter Title Forum Replies Date
D VBA code to select a signature from the signatures list Outlook VBA and Custom Forms 3
DDB VBA to Auto Insert Date and Time in the signature Outlook VBA and Custom Forms 2
M HTML email signature in Outlook Using Outlook 3
B Adding signature to bottom of VBA reply email Outlook VBA and Custom Forms 1
Martull Forced signature when multiple accounts exist Outlook VBA and Custom Forms 4
B Importing business card into Outlook for SIgnature Using Outlook 1
H Custom Signature Not Displayed When Account Selected Outlook VBA and Custom Forms 10
N How to remove signature formatting from Text in Word (accidentally taken from Outlook) Using Outlook 0
M Help sending email but removing signature via VBA Outlook VBA and Custom Forms 5
JackBlack What tools do you use to create the signature for email? Using Outlook 3
N Signature displaying incorrectly in email Using Outlook 1
Morgan Fowler Remove Signature Using Outlook 1
L Block email signature image Using Outlook 1
N Does a Shared Folder Policy override a Digital Signature Setting for macros? Outlook VBA and Custom Forms 6
J Remove extra line above signature in reply Outlook VBA and Custom Forms 5
C Macro to send email after changing from address and adding signature Outlook VBA and Custom Forms 1
skylark53 Loss of default format on deleting signature Using Outlook 5
V incorrect html signature printed Using Outlook 2
G Linked (online) signature images Using Outlook 5
O VBA to change message format and add formatted signature Outlook VBA and Custom Forms 1
Brendan.Z Outlook 2013 signature editing issue Using Outlook 3
J Outlook 2013 crashes saving VBA & clicking tools | digital signature Outlook VBA and Custom Forms 1
JorgeDario how to check a MailItem has a digital signature (SMIME) with vba? Outlook VBA and Custom Forms 1
blashmet Outlook Signature Distorted in Other Email Clients Using Outlook 9
B Oultlook 2007 Signature back ups Using Outlook 4
Ramy Wassef Signature Using Outlook 1
SirFishAlot SIGNATURE EMBED ISSUE OUTLOOK 2013 BCM (Business Contact Manager) 10
J Macro generating email using default signature and hyperlink Outlook VBA and Custom Forms 5
G Onding e-mail with wrong signature Using Outlook 0
T Setting a Default Subject from a certain Signature Using Outlook 0
B Signature Reply Issue Using Outlook 1
D Digital Signature Exchange Server Administration 1
S signature in meeting request Using Outlook 2
C Unusual Signature & Spell Check Query Using Outlook 1
R automatic signature Using Outlook 0
L Auto Reply Signature Using Outlook 5
X Outlook 2007+ Changing signature also changes subject? Using Outlook 9
L Automatically change signature based on to / cc field (@customerdomain.com) Using Outlook 2
S Outlook 2k/2k3 Reply or Forward: Signature image replaced by original sender Using Outlook 3
E Outlook Signature GPO issues Using Outlook 2
K Default Account and Signature Selection Using Outlook 5
A Vanishing signature image in Outlook 2010 Using Outlook 1
T Is there a way to apply a macro before a signature is applied in email? Using Outlook 1
E Signature changes font of last line of template Using Outlook 18
T Header instead of just a signature for a disclaimer Using Outlook 1
G Email Signature Using Outlook 1
S Signature size limit for OWA / Exchange 2010 Exchange Server Administration 10
F How to setup signature with Outlook 2007 with external picture Using Outlook 4
S macro to include email signature Outlook VBA and Custom Forms 4
D Unable to resize image in email signature Using Outlook 4

Similar threads

Back
Top