Results 1 to 5 of 5
  1. #1
    Star Lounger
    Join Date
    Jul 2002
    Posts
    58
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Letter/Legal Size Choices (Word 2000)

    I have about 3000 Word 2000 documents that were created in letter size but need to be changed to legal size documents. Is there a registery hack that will allow me to change all the documents to legal size. I would like to avoid going to each document and manualy change it. And how can I make Word 2000 create all new documents in a legal format automatically?

    Thanks

    Rumblebellly

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Letter/Legal Size Choices (Word 2000)

    >> Is there a registery hack that will allow me to change all the documents to Legal size.

    No, page settings are stored in each document, not in the Registry. You will have to create a macro that loops through all documents:
    - Open document
    - Set page size to Legal
    - Close and save document.
    - Move to next document.

    >> And how can I make Word 2000 create all new documents in a legal format automatically?

    Open the Normal.dot template (this is used for new blank documents).
    Set the page size to Legal.
    Modify the Header and Footer styles.
    Close and Save the template.
    Repeat for other templates you use.

  3. #3
    Star Lounger
    Join Date
    Jul 2002
    Posts
    58
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Letter/Legal Size Choices (Word 2000)

    How can I get the macro to open the next document or do I have to open each one and run the macro?

    Thanks

    Rbelly

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Letter/Legal Size Choices (Word 2000)

    The easiest way is to use the Dir instruction to loop through the files in a folder. Using FileSystemObject from the scripting library is more elegant, but in corporate environments scripting is often disabled. If your files are in several folders, you could adapt the following macro to handle those.

    Here is the basic outline of a macro that loops through all .doc files in a folder:

    Sub LoopThroughDocuments()
    Dim strPath As String
    Dim strFile As String
    Dim doc As Document

    On Error GoTo ErrHandler

    ' Substitute your path here
    strPath = "F:Word"

    strFile = Dir(strPath & "*.doc")
    Do While strFile <> ""
    ' Open document.
    Set doc = Documents.Open(strPath & strFile)
    ' Do your stuff here, for instance call another macro
    ' that updates the document.
    ' ...
    ' Close and save document.
    doc.Close SaveChanges:=wdDoNotSaveChanges
    ' Get next file name.
    strFile = Dir
    Loop

    ExitHandler:
    ' Clean up.
    Set doc = Nothing
    Exit Sub

    ErrHandler:
    ' Inform user.
    MsgBox Err.Description, vbExclamation
    Resume ExitHandler
    End Sub

  5. #5
    Star Lounger
    Join Date
    Jul 2002
    Posts
    58
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Letter/Legal Size Choices (Word 2000)

    Thank you!

    Rbelly

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •