Einfügen und Ändern der Größe eines Screenshots

Einfügen und Ändern der Größe eines Screenshots

Ich mache oft Screenshots von beliebigen Zeichnungen und möchte sie mithilfe eines Makros skalieren. Ich möchte, dass das Makro den Screenshot automatisch einfügt und ihn dann auf eine Höhe von 5,9 Zoll und eine Breite von 10 Zoll skaliert. Das aktuelle Makro, das ich verwende, funktioniert einwandfrei, solange der Screenshot nicht zu groß (in der Höhe) ist, aber ich möchte, dass er auf die nächste Breite (10) oder Höhe (5,9) angepasst wird, je nachdem, was zuerst eintritt. Irgendwelche Vorschläge?

Kyle

Sub Resize()

  If ActiveDocument.Shapes.Count = 3 Then
    ActiveDocument.Shapes(3).Select
    Selection.shapeRange.Delete
  End If
  Application.ScreenUpdating = False
  Selection.Paste
  If ActiveDocument.InlineShapes.Count = 1 Then
    ActiveDocument.InlineShapes(1).ConvertToShape
  End If
  If ActiveDocument.Shapes.Count = 3 Then
    With ActiveDocument.Shapes(3)
      .WrapFormat.Type = wdWrapFront
      .LockAspectRatio = msoTrue
      .Height = InchesToPoints(5.9)
     ' .Width = InchesToPoints(10)

      .RelativeHorizontalPosition = wdRelativeHorizontalPositionPage
     .RelativeVerticalPosition = wdRelativeVerticalPositionPage
      .Top = InchesToPoints(0.8) 
      .Left = wdShapeCenter 
    End With
  End If
  Application.ScreenUpdating = True
End Sub

verwandte Informationen