Reduce RTF file size RRS feed

  • Question

  • Hello all,

    does Microsoft Word offer any option to reduce the file size of documents saved in RTF format with a VBA macro? I've compared the file sizes of RTF files generated with WordPad and those generated with Microsoft Word 2010. When the RTF contains images, Word produces files that are up to 10 times larger than the WordPad RTFs with the same content.

    I know that there is an registry option "ExportPictureWithMetafile" which indeed helps reducing the file size when set to "0"  (http://support.microsoft.com/?id=224663), but is it possible to use a VBA command or an affordable third-party tool/add-on to achieve the desired result? Perhaps there is a way to automate WordPad (pasting RTF from clipboard and save as RTF file)?

    Thanks in advance.

    Friday, August 19, 2016 8:25 PM


  • One reason an RTF file produced by Word would be larger than one produced by WordPad is that the Word RTF will contain a lot of data regarding Styles, etc., which WordPad doesn't support.

    You could indeed automate WordPad, using code like:

    Sub Demo()
    Dim StrWdPd As String, StrFlNm As String
    StrWdPd = Environ("ProgramFiles") & "\Windows NT\Accessories\WordPad.exe"
    StrFlNm = "C:\Users\" & Environ("Username") & "\Documents\Test.rtf"
    Shell StrWdPd & " " & Chr(34) & StrFlNm & Chr(34), vbNormalFocus
    SendKeys "^s%fx"
    End Sub

    Paul Edstein
    [MS MVP - Word]

    Saturday, August 20, 2016 3:31 AM