none
Tree text / drop down RRS feed

  • Question

  • I am trying to find out how to do something that I would think is really simple.

    I have a section of a page and its structured like this:

    SECTION TITLE

           TOPIC ONE
              -SOMETHING
              -SOMETHING
              -SOMETHING

    What i want it to look like is this:
             - TOPIC ONE

    When you click Topic one, or an arrow or something beside it - it shows the (somethings) beneath it. So its a way to hide what is under it. I want to preserve the formatting, color etc.

    Are there any examples of how this can be done ? Thanks!

    Tuesday, February 1, 2011 3:48 PM

Answers

  • Hi Bruce / Tntelle

    I understand why the question was asked in a programming group - what Tntelle wants doesn't exist in the Word user interface. Word is not a browser and is not designed to function like one. The only place this kind of thing is available in the UI is in the "Outline view".

    Something like that can be programmed, but I don't have the time currently to follow-up with code detail, which is why I avoided the question, leaving for others...

    The only way you can do this is to format the text as hidden/unhidden, usually through the use of style pairs or changing the style definition. Or the formatting of the range can be changed, although that's less elegant.

    To get the "on click" effect you'd need to use the WindowSelectionChange event (or place the text in a MacroButton field). That makes this not a coding task for the beginner... Unfortunately, I don't know of any links where this is covered, although I'm certain it was discussed in the old newsgroups. Possibly, a search of "Google Groups" could turn something up.


    Cindy Meister, VSTO/Word MVP
    • Marked as answer by Bessie Zhao Tuesday, February 8, 2011 9:35 AM
    Friday, February 4, 2011 3:12 PM
    Moderator

All replies

  • Hi Tntelle,

    Thank you for posting.

    This forum is for Excel development. I think your problem is an end user problem not a developer one. If you post your problem on this website: http://social.answers.microsoft.com/Forums/en-US/wordcreate/threads, you may get more help from there.

    Best Regards,


    Bruce Song [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Friday, February 4, 2011 10:30 AM
  • Hi Bruce / Tntelle

    I understand why the question was asked in a programming group - what Tntelle wants doesn't exist in the Word user interface. Word is not a browser and is not designed to function like one. The only place this kind of thing is available in the UI is in the "Outline view".

    Something like that can be programmed, but I don't have the time currently to follow-up with code detail, which is why I avoided the question, leaving for others...

    The only way you can do this is to format the text as hidden/unhidden, usually through the use of style pairs or changing the style definition. Or the formatting of the range can be changed, although that's less elegant.

    To get the "on click" effect you'd need to use the WindowSelectionChange event (or place the text in a MacroButton field). That makes this not a coding task for the beginner... Unfortunately, I don't know of any links where this is covered, although I'm certain it was discussed in the old newsgroups. Possibly, a search of "Google Groups" could turn something up.


    Cindy Meister, VSTO/Word MVP
    • Marked as answer by Bessie Zhao Tuesday, February 8, 2011 9:35 AM
    Friday, February 4, 2011 3:12 PM
    Moderator