Word.Tips.Net Welcome toWord.Tips.Net

Helpful Links

Tips.Net Home
WordTips Home

Ask a Word Question
Make a Comment

Tips.Net Store

WordTips FAQ
WordTips Premium

Learn Access Now
Free Printable Forms

Beauty Tips
Car Tips
Cleaning Tips
College Tips
Cooking Tips
Excel2007 Tips
ExcelTips
Family Tips
Gardening Tips
Health Tips
Home Tips
Legal Tips
Money Tips
Organizing Tips
Pest Tips
Pet Tips
Wedding Tips
Word2007 Tips
WordTips

Advertise on the
WordTips Site

Newest Tips

Printing On Both Sides of the Paper

Turning Off AutoComplete for Dates

Ordering Search and Replace

Understanding Auto Line Spacing

Adding Comments to Your Document

Conditional Calculations in Word

Determining Word Frequency

 

Automatically Formatting an ASCII File with WordBasic

Summary: Use this simple WordBasic macro to help remove hard returns from inappropriate places in an ASCII file. (This tip works with Microsoft Word 6, and Word 95.)

One of the biggest problems in formatting what was previously an ASCII file is modifying it so there are only hard returns at the end of paragraphs. Most ASCII files have a hard return at the end of every line of the file, and two hard returns at the end of every paragraph. If you have an ASCII file that is formatted like this, such as something you downloaded off the Internet, the following WordBasic macro will be invaluable. It formats an entire file so there are only hard returns at the end of paragraphs.

Sub MAIN
    EditFindClearFormatting
    EditReplaceClearFormatting
    Fmt("^p^p", "{|}")
    Fmt("^p", " {@}")
    Fmt(" {@}", " ")
    Fmt("{@}", " ")
    Fmt("{|}", "^p")
End Sub

Sub Fmt(FromWord$, ToWord$)
    StartOfDocument
    EditReplace .Find = FromWord$, .Replace = ToWord$, .WholeWord = 0, \
    .MatchCase = 0, .Format = 0, .ReplaceAll = 1
End Sub

Tip #186 applies to Microsoft Word versions: 6 | 95

Create Rock-Solid Lists! Bulleted and numbered lists can help make your writing clearer and easier to follow. If not done properly, however, they can be a nightmare to work with. Discover the ins and outs of Word's lists with this great reference available in two versions.
 
Check out Word Bullets and Numbering today!