December 29, 2012

HTML to doc - microsoft word script (delete all of unnecessary enters)

I you want to print a web page this is the best way to save papers. A HTML document is a webpage, so you could simple open it up using a web browser (IE, Firefox etc.), copy everything there and paste it into a word document. Create a macro in windows word, give it a name and copy this text:


Selection.HomeKey Unit:=wdStory ' A dokumentum elejére állunk.
ActiveDocument.Select
With Selection.Find
    .Text = "^p^p"
    .Replacement.Text = "^p"
    .Execute Replace:=wdReplaceAll, Forward:=True, _
        Wrap:=wdFindContinue
End With
Selection.HomeKey Unit:=wdStory ' A dokumentum elejére állunk.
ActiveDocument.Select
With Selection.Find
    .Text = "^p^p"
    .Replacement.Text = "^p"
    .Execute Replace:=wdReplaceAll, Forward:=True, _
        Wrap:=wdFindContinue
End With
Selection.HomeKey Unit:=wdStory ' A dokumentum elejére állunk.


Use this script. This script deletes all of unnecessary enters  from your documents.

-->

No comments:

Post a Comment