Outlook - Nachrichtenformat und Signaturen: Unterschied zwischen den Versionen
(Die Seite wurde neu angelegt: „== Links == == Signaturen == Liegen hier: Win+R %APPDATA%\Microsoft\Signatures == Nachrichtenformat == Outlook kann Nachrichten als Text, HTML oder RTF ve…“) |
|||
| Zeile 17: | Zeile 17: | ||
| − | <syntaxhighlight lang=" | + | <syntaxhighlight lang="visualbasic"> |
Sub ForceReplyInHTML() | Sub ForceReplyInHTML() | ||
Version vom 12. Dezember 2022, 18:14 Uhr
Links
Signaturen
Liegen hier:
Win+R %APPDATA%\Microsoft\Signatures
Nachrichtenformat
Outlook kann Nachrichten als Text, HTML oder RTF versenden. RTF geht nur von Outlook nach Outlook.
Das Format kann man unter Textformat einstellen. Outlook versucht immer im gleichen Format zu antworten mit dem Mail ankommen. Also mit Text wenn jemand Textmails schickt.
Man kann ein Makro erstellen und mit einem Button verknüpfen wenn man immer mit HTML antworten möchte:
In HTML antworten Button
Makro anlegen
<syntaxhighlight lang="visualbasic">
Sub ForceReplyInHTML()
'================================================================= 'Description: Outlook macro to reply to a message in HTML ' regardless of the current message format. ' The reply will use your HTML signature as well. ' 'author : Robert Sparnaaij 'version: 1.0 'website: https://www.howto-outlook.com/howto/replyinhtml.htm '=================================================================
Dim objOL As Outlook.Application
Dim objSelection As Outlook.Selection
Dim objItem As Object
Set objOL = Outlook.Application
'Get the selected item
Select Case TypeName(objOL.ActiveWindow)
Case "Explorer"
Set objSelection = objOL.ActiveExplorer.Selection
If objSelection.Count > 0 Then
Set objItem = objSelection.Item(1)
Else
Result = MsgBox("No item selected. " & _
"Please make a selection first.", _
vbCritical, "Reply in HTML")
Exit Sub
End If
Case "Inspector"
Set objItem = objOL.ActiveInspector.CurrentItem
Case Else
Result = MsgBox("Unsupported Window type." & _
vbNewLine & "Please make a selection" & _
" or open an item first.", _
vbCritical, "Reply in HTML")
Exit Sub
End Select
Dim olMsg As Outlook.MailItem
Dim olMsgReply As Outlook.MailItem
Dim IsPlainText As Boolean
'Change the message format and reply
If objItem.Class = olMail Then
Set olMsg = objItem
If olMsg.BodyFormat = olFormatPlain Then
IsPlainText = True
End If
olMsg.BodyFormat = olFormatHTML
Set olMsgReply = olMsg.Reply
If IsPlainText = True Then
olMsg.BodyFormat = olFormatPlain
End If
olMsg.Close (olSave)
olMsgReply.Display
'Selected item isn't a mail item
Else
Result = MsgBox("No message item selected. " & _
"Please make a selection first.", _
vbCritical, "Reply in HTML")
Exit Sub
End If
'Cleanup
Set objOL = Nothing
Set objItem = Nothing
Set objSelection = Nothing
Set olMsg = Nothing
Set olMsgReply = Nothing
End Sub <syntaxhighlight>