Results 1 to 3 of 3
  1. #1
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Melbourne, Australia
    Posts
    1,294
    Thanks
    0
    Thanked 0 Times in 0 Posts

    using selection can I obtain the heading style nam (Word 2002 /XP SP3)

    Hello there

    With code I was wanting to do the following:

    with the active selection
    obtain the heading style applied to that selection
    and then make amendments to the heading style

    can I do this? i was looking thru the styles properties and couldnt find anything related? <img src=/S/RollEyes.gif border=0 alt=RollEyes width=19 height=19>

    diana

  2. Subscribe to our Windows Secrets Newsletter - It's Free!

    Get our unique weekly Newsletter with tips and techniques, how to's and critical updates on Windows 7, Windows 8, Windows XP, Firefox, Internet Explorer, Google, etc. Join our 480,000 subscribers!

    Excel 2013: The Missing Manual

    + Get this BONUS — free!

    Get the most of Excel! Learn about new features, basics of creating a new spreadsheet and using the infamous Ribbon in the first chapter of Excel 2013: The Missing Manual - Subscribe and download Chapter 1 for free!

  3. #2
    Silver Lounger
    Join Date
    Mar 2001
    Location
    Springfield, Ohio, USA
    Posts
    2,136
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: using selection can I obtain the heading style nam (Word 2002 /XP SP3)

    Sure, you can do this. Put this piece of code in to get you started:
    <pre> MsgBox Selection.Style
    Dim s As Style
    Set s = ActiveDocument.Styles(Selection.Style)
    MsgBox s.Description
    </pre>

    <font face="Comic Sans MS">Sam Barrett, CACI </font face=comic>
    <small>And the things that you have heard... commit these to faithful men who will be able to teach others also. 2 Timothy 2:2</small>

  4. #3
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Melbourne, Australia
    Posts
    1,294
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: using selection can I obtain the heading style nam (Word 2002 /XP SP3)

    nice one Sam...

    diana <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

Posting Permissions

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