Results 1 to 7 of 7

Thread: [RESOLVED] Rename a minimized block of code

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Apr 2010
    Posts
    131

    Resolved [RESOLVED] Rename a minimized block of code

    The question is simple. I minimize a block of code, and instead of the text inside the rectangle being "..." I need to write smth of my own. I knew how to do it some long time ago, but I've forgotten it now.


  2. #2

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Apr 2010
    Posts
    131

    Re: Rename a minimized block of code

    Instead of the three dots over there, I need to write something of my own, so I know what the code within it does.

  4. #4
    Hyperactive Member
    Join Date
    Aug 2011
    Posts
    272

    Re: Rename a minimized block of code

    I think what you're wanting to do is create a region.

    Code:
    #Region "Your Text Here"
    
    Code
    
    #End Region
    Then when you collapse the region, you'll see "YOUR TEXT HERE" inside the rectangle.

  5. #5
    Hyperactive Member
    Join Date
    Jan 2012
    Location
    Florida
    Posts
    285

    Re: Rename a minimized block of code

    Code:
    #Region "Name Me"
    subs n stuffs goes here
    #Region
    I have been beaten by the swiftness.

  6. #6
    Frenzied Member MattP's Avatar
    Join Date
    Dec 2008
    Location
    WY
    Posts
    1,227

    Re: Rename a minimized block of code

    You can also make an XML comment that will show up when minimized.

    Code:
        '''<summary>
        ''' This is a multiline comment
        ''' I want to show when minimized
        '''</summary>
    
        '''<summary>Here's some more minimized text</summary>
    This pattern in common to all great programmers I know: they're not experts in something as much as experts in becoming experts in something.

    The best programming advice I ever got was to spend my entire career becoming educable. And I suggest you do the same.

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Apr 2010
    Posts
    131

    Re: Rename a minimized block of code

    Quote Originally Posted by samuelk View Post
    I think what you're wanting to do is create a region.

    Code:
    #Region "Your Text Here"
    
    Code
    
    #End Region
    Then when you collapse the region, you'll see "YOUR TEXT HERE" inside the rectangle.
    Yap, that's what I was talking about. Sad it doesn't work within subs, but still useful in other areas, so thanks to you and to all the other replies.

Posting Permissions

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



Click Here to Expand Forum to Full Width