Results 1 to 7 of 7
  1. #1
    3 Star Lounger
    Join Date
    Aug 2002
    Location
    milton keynes, Buckinghamshire
    Posts
    252
    Thanks
    0
    Thanked 0 Times in 0 Posts

    increase font size (2003)

    I sometimes extract word files from pdf's. However the extracted files as downloaded come with a small font size which varies not only from paragraph to paragraph but also within paragraphs. I need to keep the font size differences, but for the sale of my eyesight need to increase the font size of each character within the document. The files also contain pictures.

    I wrote the following macro within normal.doc to automatically increase the font size by 1. However th macro takes a long time to run (6000 characters out of a document with 390,000 characters took 5 minutes!) Can anybody assist with different version of the macro?

    Sub IncreaseSize()
    Dim i As Long
    i = Selection.Characters.Count
    Dim j As Long
    j = 1
    Dim CurrentFontSize As Integer
    While j <= i
    With Selection.Characters(j)
    CurrentFontSize = .Font.Size
    .Font.Size = CurrentFontSize + 1
    j = j + 1
    End With
    Wend

    End Sub

  2. #2
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: increase font size (2003)

    Unless you need the fonts to be bigger for a printout, I probably would use the Zoom setting instead. It is accessible from the Standard toolbar (assuming it hasn't shrunk itself to save on space) or View>Zoom. This setting will be saved with your document, if you save it, but it should not affect other existing documents. It might affect new documents (I'll admit, I find it a bit unpredictable).

  3. #3
    3 Star Lounger
    Join Date
    Aug 2002
    Location
    milton keynes, Buckinghamshire
    Posts
    252
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: increase font size (2003)

    Yes, sorry I did not mention that the purpose of this exercise is so as to be able to print the enlarged font

  4. #4
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: increase font size (2003)

    We've had a couple of threads on this board and/or on the VBA board about selecting ranges of text or paragraphs based on various criteria, including style name. Probably one of those could be adapted to look at font size. Maybe try this thread first: Iterating Word objects efficiently (Word VBA).

  5. #5
    3 Star Lounger
    Join Date
    Apr 2004
    Location
    Boston, Massachusetts, USA
    Posts
    389
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: increase font size (2003)

    It's not always a 1-point increment (depend on the current size), but have you tried the Grow command? Ctrl+Shift+>

  6. #6
    New Lounger
    Join Date
    Mar 2005
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: increase font size (2003)

    Hi. I do this for my own docs by selecting everything and then using Ctrl+] (closing square bracket), which raises the font and works strictly in 1 point increments (Ctrl+[ does the opposite). While I haven't used it extensively, I've always had success across paragraphs with different font sizes.

  7. #7
    3 Star Lounger
    Join Date
    Aug 2002
    Location
    milton keynes, Buckinghamshire
    Posts
    252
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: increase font size (2003)

    Thanks

    The grow size button works

Posting Permissions

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