I am trying to create a macro in Word that will take a portion of the document that I copy using selection.copy. Then use
ActiveDocument.SaveAs FileName:= (Whatever I had copied to the clipboard)
Here is the code
Sub Macro1()
Selection.HomeKey Unit:=wdStory
Selection.MoveDown Unit:=wdLine, Count:=7, Extend:=wdExtend
Selection.TypeBackspace
Selection.MoveDown Unit:=wdLine, Count:=15
Selection.EndKey Unit:=wdLine, Extend:=wdExtend
Selection.Copy
ActiveDocument.SaveAs FileName:= _
"this is what I want to paste", _
FileFormat:=wdFormatDocument, LockComments:=False, Password:="", _
AddToRecentFiles:=True, WritePassword:="", ReadOnlyRecommended:=False, _
EmbedTrueTypeFonts:=False, SaveNativePictureFormat:=False, SaveFormsData _
:=False, SaveAsAOCELetter:=False
End Sub
Any help would be appreciated
ActiveDocument.SaveAs FileName:= (Whatever I had copied to the clipboard)
Here is the code
Sub Macro1()
Selection.HomeKey Unit:=wdStory
Selection.MoveDown Unit:=wdLine, Count:=7, Extend:=wdExtend
Selection.TypeBackspace
Selection.MoveDown Unit:=wdLine, Count:=15
Selection.EndKey Unit:=wdLine, Extend:=wdExtend
Selection.Copy
ActiveDocument.SaveAs FileName:= _
"this is what I want to paste", _
FileFormat:=wdFormatDocument, LockComments:=False, Password:="", _
AddToRecentFiles:=True, WritePassword:="", ReadOnlyRecommended:=False, _
EmbedTrueTypeFonts:=False, SaveNativePictureFormat:=False, SaveFormsData _
:=False, SaveAsAOCELetter:=False
End Sub
Any help would be appreciated