Препратете маркиран имейл до конкретен получател

Как да препратя маркиран имейл до конкретен получател?

Възможно ли е да се свърже това с пряк път CTRL-ALT-?

Аз съм с Windows 7, Outlook 2010


person eurekaent    schedule 16.12.2011    source източник


Отговори (2)


Ctrl+Alt изглежда не е функция на Outlook 2003, така че не мога да коментирам. Мога да стартирам следния макрос, като добавя макроса към лента с инструменти с помощта на Инструменти, Персонализиране.

Този макрос ще препрати всички избрани елементи. Ако искате да сте сигурни, че е избран само един елемент, тествайте SelectedItems.Count. Ако текущата папка е празна, нищо не се случва, защото SelectedItems.Count = 0

Sub ForwardSelectedItems()

  Dim Inx As Integer
  Dim NewItem As MailItem
  Dim SelectedItems As Outlook.Selection

  Set SelectedItems = ActiveExplorer.Selection

  For Inx = 1 To SelectedItems.Count
    Set NewItem = SelectedItems.Item(Inx).Forward
    With NewItem
      ' ##########   Remove following block if attachments are to be sent.
      ' Delete any attachments.
      With .Attachments
        While .Count > 0
          .Remove 1
        Wend
      End With
      ' ##########   Remove above block if attachments are to be sent.
      With .Recipients
      ' Add new recipient.  Note Forward deletes existing recipients.
        .Add "[email protected]"
      End With
      ' Choices   ######
      '.Display           ' Show to user and let them send if they wish
      .Send               ' Send automatically without showing to user
      ' End of choices  ######
    End With
  Next

End Sub
person Tony Dallimore    schedule 21.12.2011
comment
@eurekaent. Беше ли този отговор задоволителен? Ако не, по какъв начин не отговаря на вашите изисквания? - person Tony Dallimore; 04.01.2012

Препратете маркиран имейл до конкретен получател

Върнете текущо маркирания имейл:

GetCurrentItem ще върне текущо избрания или отворен имейл към процедурата за повикване.

Function GetCurrentItem() As Object
' returns reference to current item, either the one
' selected (Explorer), or the one currently open (Inspector)

  Select Case True
  Case IsExplorer(Application.ActiveWindow)
    Set GetCurrentItem = ActiveExplorer.Selection.item(1)
  Case IsInspector(Application.ActiveWindow)
    Set GetCurrentItem = ActiveInspector.CurrentItem
  End Select

End Function
Function IsExplorer(itm As Object) As Boolean
  IsExplorer = (TypeName(itm) = "Explorer")
End Function
Function IsInspector(itm As Object) As Boolean
  IsInspector = (TypeName(itm) = "Inspector")
End Function

Препратете избрания имейл:

Това използва горните функции за препращане и показване на имейл. Останалото зависи от вас.

Sub FwdMail()

Dim obj As Object
Dim msg As Outlook.MailItem

Set obj = GetCurrentItem

If TypeName(obj) = "MailItem" Then
  Set msg = obj
  With msg
    .Forward
    .Display
  End With
End If

End Sub
person JimmyPena    schedule 24.07.2012