Thread View: microsoft.public.word.vba
1 messages
1 total messages
Started by comicnut
Wed, 30 Aug 2023 17:14
Help please: macro to save various html as rtf
Author: comicnut
Date: Wed, 30 Aug 2023 17:14
Date: Wed, 30 Aug 2023 17:14
28 lines
1645 bytes
1645 bytes
I'm converting a number of htmls with different filenames to rtf after
using other macros to reformat.
I recorded a macro of saving an html file as rtf. Looking at the macro
in vba, it specifies saving the file as a specific filename to a
specific directory which would overwrite other files. I want to alter
this macro to automatically save the filename and directory as the
current active document
Any ideas?
Here's the recorded macro:
Sub savertf1()
'
' savertf1 Macro
'
'
ChangeFileOpenDirectory "D:\New folder\"
ActiveDocument.SaveAs2 FileName:="test123.rtf",
FileFormat:=wdFormatRTF, _
LockComments:=False, Password:="", AddToRecentFiles:=True,
WritePassword _
:="", ReadOnlyRecommended:=False, EmbedTrueTypeFonts:=False, _
SaveNativePictureFormat:=False, SaveFormsData:=False,
SaveAsAOCELetter:= _
False, CompatibilityMode:=0
End Sub
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads