none
Accessing New Mail Item RRS feed

  • Question

  • I need to know, If it possible to get or set the input position in currently open mail item.
    Wednesday, June 13, 2012 8:09 PM

Answers

  • Outlook version?
     
    If it's 2007 or 2010 or a 2003 WordMail item use Inspector.WordEditor for the open Inspector to get a Word.Document object. Use the Word object model to get/set the cursor position.
     
    If it's 2003 and it's using the Outlook editor you'd need to use the Redemption.SafeInspector object, unless it's HTML. Then you could get an IHTMLDocument object and use the DOM to get the cursor position.

    --
    Ken Slovak
    [MVP-Outlook]
    http://www.slovaktech.com
    Author: Professional Programming Outlook 2007
    "GDudi" <=?utf-8?B?R0R1ZGk=?=> wrote in message news:22776785-efd3-4f18-afd7-2da3885f0f38...
    I need to know, If it possible to get or set the input position in currently open mail item.

    Ken Slovak MVP - Outlook
    Wednesday, June 13, 2012 9:33 PM
    Moderator

All replies

  • Outlook version?
     
    If it's 2007 or 2010 or a 2003 WordMail item use Inspector.WordEditor for the open Inspector to get a Word.Document object. Use the Word object model to get/set the cursor position.
     
    If it's 2003 and it's using the Outlook editor you'd need to use the Redemption.SafeInspector object, unless it's HTML. Then you could get an IHTMLDocument object and use the DOM to get the cursor position.

    --
    Ken Slovak
    [MVP-Outlook]
    http://www.slovaktech.com
    Author: Professional Programming Outlook 2007
    "GDudi" <=?utf-8?B?R0R1ZGk=?=> wrote in message news:22776785-efd3-4f18-afd7-2da3885f0f38...
    I need to know, If it possible to get or set the input position in currently open mail item.

    Ken Slovak MVP - Outlook
    Wednesday, June 13, 2012 9:33 PM
    Moderator
  • It's for Outlook 2007 & 2010.

    I did not use WordEditor until now, so I'm nit familiar with it, Can you tell me what function in WordEditor I can use for it, or give me a little code example?

    Thursday, June 14, 2012 3:20 AM
  • How ca I get IHTMDocument from Outlook 2007 & 2010?
    Thursday, June 14, 2012 3:25 AM
  • You can't. For those versions you would use WordEditor, which is a Word.Document object. Once you have that from the Inspector object you must use the Word object model. Cast WordEditor to Document.

    --
    Ken Slovak
    [MVP-Outlook]
    http://www.slovaktech.com
    Author: Professional Programming Outlook 2007
    "GDudi" <=?utf-8?B?R0R1ZGk=?=> wrote in message news:8572812b-0aa5-402a-a4d3-d3eb6aabbefc...
    How ca I get IHTMDocument from Outlook 2007 & 2010?

    Ken Slovak MVP - Outlook
    Monday, June 18, 2012 6:35 PM
    Moderator
  • WordEditor is Word.Document. Just cast it to that and use the Word object model.

    --
    Ken Slovak
    [MVP-Outlook]
    http://www.slovaktech.com
    Author: Professional Programming Outlook 2007
    "GDudi" <=?utf-8?B?R0R1ZGk=?=> wrote in message news:cacb7d37-2e21-4210-8b61-e2d857692f27...

    It's for Outlook 2007 & 2010.

    I did not use WordEditor until now, so I'm nit familiar with it, Can you tell me what function in WordEditor I can use for it, or give me a little code example?


    Ken Slovak MVP - Outlook
    Monday, June 18, 2012 6:35 PM
    Moderator