Outlook Banter

Outlook Banter (http://www.outlookbanter.com/)
-   Outlook and VBA (http://www.outlookbanter.com/outlook-vba/)
-   -   Using Word as Editor through VBA (http://www.outlookbanter.com/outlook-vba/75786-using-word-editor-through-vba.html)

RW July 25th 08 05:22 PM

Using Word as Editor through VBA
 
Using Word as the default editor has been turned off by the admins. However,
one can select it by customizing the tool bar and adding Microsoft Word from
the Actions group.

The problem with this is that it isn't used when replying to emails unless
one copies the email they are replying to and pasting it into word.

Is there a way to write a macro that would allow one to reply using Word? In
other words, a macro whose icon I can put on the toolbar to replace the
current Reply and one to replace Reply to All? Or even better, a macro the
user can click on when Outlook is opened and it will set Word as the default
editor?

Ken Slovak - [MVP - Outlook] July 25th 08 08:55 PM

Using Word as Editor through VBA
 
You'd need to write to the Windows registry when Outlook was closed down,
the setting for that is only read from the registry on startup. Any changes
after that are written to the registry and the current setting is maintained
in an in-memory cache, but the registry setting isn't read again.

Of course if you do that you run the risk of running afoul of your admins if
you're caught.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"RW" wrote in message
...
Using Word as the default editor has been turned off by the admins.
However,
one can select it by customizing the tool bar and adding Microsoft Word
from
the Actions group.

The problem with this is that it isn't used when replying to emails unless
one copies the email they are replying to and pasting it into word.

Is there a way to write a macro that would allow one to reply using Word?
In
other words, a macro whose icon I can put on the toolbar to replace the
current Reply and one to replace Reply to All? Or even better, a macro the
user can click on when Outlook is opened and it will set Word as the
default
editor?



RW July 26th 08 01:39 AM

Using Word as Editor through VBA
 
The PC is on Citrix thus the registry can not be accessed.

Is there a way to write a macro that would capture the email being read and
open Word as the editor? I can use Word as the editor for new emails because
I have it as an icon on the toolbar (got it from the action menu under
customizing the toolbar). I need to be able to easily use it for Reply and
Reply to All.

Thanks


"Ken Slovak - [MVP - Outlook]" wrote:

You'd need to write to the Windows registry when Outlook was closed down,
the setting for that is only read from the registry on startup. Any changes
after that are written to the registry and the current setting is maintained
in an in-memory cache, but the registry setting isn't read again.

Of course if you do that you run the risk of running afoul of your admins if
you're caught.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"RW" wrote in message
...
Using Word as the default editor has been turned off by the admins.
However,
one can select it by customizing the tool bar and adding Microsoft Word
from
the Actions group.

The problem with this is that it isn't used when replying to emails unless
one copies the email they are replying to and pasting it into word.

Is there a way to write a macro that would allow one to reply using Word?
In
other words, a macro whose icon I can put on the toolbar to replace the
current Reply and one to replace Reply to All? Or even better, a macro the
user can click on when Outlook is opened and it will set Word as the
default
editor?




Ken Slovak - [MVP - Outlook] July 26th 08 05:23 PM

Using Word as Editor through VBA
 
If you create a macro to open Word it would be an independent document
window and not an email. So you'd have to create a new email, then copy the
text from the open one or one you are reading in the preview pane.

However, that would not be a reply message it would be a new one, with none
of the conversation indexing, addressing and other characteristics of an
actual reply message.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"RW" wrote in message
...
The PC is on Citrix thus the registry can not be accessed.

Is there a way to write a macro that would capture the email being read
and
open Word as the editor? I can use Word as the editor for new emails
because
I have it as an icon on the toolbar (got it from the action menu under
customizing the toolbar). I need to be able to easily use it for Reply and
Reply to All.

Thanks



RW July 26th 08 06:09 PM

Using Word as Editor through VBA
 
OK, I don't want to open Word as Word. If you customize the toolbar of
Outlook and under the Tools section, there is an Action group. Within this
group is MS Word as html. When used, this opens Word as the email editor.
This is still available on our PC's and works but only for new email.

What I need is a macro that will copy the email one is reading / is active
(including the To, CC, Subject, etc) and paste it into the Word email editor
after opening it. If one uses the newly created Reply macro, then the To and
subject would automatically be filled out. If one used the newly created
Reply to All macro then the To and Cc lines would also be filled out
automatically. Is any of this possible?

I appreciate any help you can provide. Thanks


"Ken Slovak - [MVP - Outlook]" wrote:

If you create a macro to open Word it would be an independent document
window and not an email. So you'd have to create a new email, then copy the
text from the open one or one you are reading in the preview pane.

However, that would not be a reply message it would be a new one, with none
of the conversation indexing, addressing and other characteristics of an
actual reply message.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"RW" wrote in message
...
The PC is on Citrix thus the registry can not be accessed.

Is there a way to write a macro that would capture the email being read
and
open Word as the editor? I can use Word as the editor for new emails
because
I have it as an icon on the toolbar (got it from the action menu under
customizing the toolbar). I need to be able to easily use it for Reply and
Reply to All.

Thanks




Ken Slovak - [MVP - Outlook] July 26th 08 06:45 PM

Using Word as Editor through VBA
 
Yes, it's possible, but as I said it won't be a reply message, it will be a
brand new one. You'd also have to get the original recipients and reverse
them so the sender of the original would be the recipient of the fake reply
and the recipient of the original was the new sender.

The To, CC, etc. fields will show the email display name, not the actual
email addresses. Those might be usable for emailing or might not be. If
"Joe" sends you something that might not mean anything when replying.

If you are reading an email then you would get it as
ActiveExplorer.Selection(1). If you have it opened it would be
ActiveInspector.CurrentItem.

From there you can read HTMLBody for an HTML message or Body for a plain
text message, Subject, To, Cc, etc. If you want the actual recipients you
would access the Recipients collection of the original item and iterate each
recipient.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"RW" wrote in message
...
OK, I don't want to open Word as Word. If you customize the toolbar of
Outlook and under the Tools section, there is an Action group. Within this
group is MS Word as html. When used, this opens Word as the email editor.
This is still available on our PC's and works but only for new email.

What I need is a macro that will copy the email one is reading / is active
(including the To, CC, Subject, etc) and paste it into the Word email
editor
after opening it. If one uses the newly created Reply macro, then the To
and
subject would automatically be filled out. If one used the newly created
Reply to All macro then the To and Cc lines would also be filled out
automatically. Is any of this possible?

I appreciate any help you can provide. Thanks




All times are GMT +1. The time now is 11:35 PM.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com