dcsimg
Results 1 to 5 of 5

Thread: [RESOLVED] How to make my own functions show a tooltip (or the nane it has)

  1. #1

    Thread Starter
    Member
    Join Date
    Jul 2018
    Posts
    41

    Resolved [RESOLVED] How to make my own functions show a tooltip (or the nane it has)

    Hi all,

    It's a bit stupid question, but I've googled it but don't find correct keywords and I'm not capable of finding an answer.

    When I use a system function, in the moment of writing the code Visual Studio shows this window:



    It shows a text with the explanation of the function.

    When I use my own functions, of course, there is no explanation, only the detail of accepted variables:



    How can I make my functions have this? I mean, It's obvious I'll have to write it in the code, but where and in what way??

    Regards and thanks

  2. #2
    .NUT jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    102,363

    Re: How to make my own functions show a tooltip (or the nane it has)


  3. #3

    Thread Starter
    Member
    Join Date
    Jul 2018
    Posts
    41

    Re: How to make my own functions show a tooltip (or the nane it has)

    Quote Originally Posted by jmcilhinney View Post
    Perfect!

    I was writing the comments using simply // before de declaration of the function. Now, when I write /// the magic begins since it complete automatically all the summary labels.

    One thing very important if someone read this and want to do this with their functions: Don't use & character on the comments, if you do it it will not work and no text will be displayed! I've spent a long time this this until I discovered the problem, I were about of commiting suicide :P

    Regards!
    Last edited by TassadarNET; Mar 20th, 2019 at 02:52 PM.

  4. #4
    .NUT jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    102,363

    Re: How to make my own functions show a tooltip (or the nane it has)

    Quote Originally Posted by TassadarNET View Post
    One thing very important if someone read this and want to do this with their functions: Don't use & character on the comments, if you do it it will not work and no text will be displayed! I've spent a long time this this until I discovered the problem, I were about of commiting suicide :P
    It's called "XML documentation" for a reason. The comments you write will be parsed as XML so, if you want an ampersand in the text, you need to use "&". The same goes for other special characters.

  5. #5

    Thread Starter
    Member
    Join Date
    Jul 2018
    Posts
    41

    Re: How to make my own functions show a tooltip (or the nane it has)

    Quote Originally Posted by jmcilhinney View Post
    It's called "XML documentation" for a reason. The comments you write will be parsed as XML so, if you want an ampersand in the text, you need to use "&". The same goes for other special characters.
    Many thanks, jmcihinney. At the first moment I thought the problem came when I edited manually the labels, later I thought it can be related with that you're telling, but I took a bit in realize what was the problematic char.

    Regards

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width