Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Low priority: Visual Studio IDE, string literals, convenience.

Low priority: Visual Studio IDE, string literals, convenience.

Scheduled Pinned Locked Moved C#
visual-studiocsharpcomhelp
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    LimitedAtonement
    wrote on last edited by
    #1

    Dear Sirs, I have used Netbeans and Eclipse IDEs, and they have a nifty feature such that while you're typing a string literal, you can press enter, and it automatically inserts end quotes, plus sign, the appropriate tabs, then beginning quotes so that if I type

    if (flag)
        string str = "There was an error in the output, you must first \[enter\]type 't', then the input.";
    

    , the output is thus:

    if (flag)
        string str = "There was an error in the output, you must first " + 
        "type 't', then the input";
    

    Is there an analogous feature in Visual Studio. Now, I have to type the end-quotes, the plus sign, enter, and the beginning quotes, and it gives me the red-squiggly the whole time. Thanks for your responses. In Christ, Aaron Laws http://ProCure.com/

    L 1 Reply Last reply
    0
    • L LimitedAtonement

      Dear Sirs, I have used Netbeans and Eclipse IDEs, and they have a nifty feature such that while you're typing a string literal, you can press enter, and it automatically inserts end quotes, plus sign, the appropriate tabs, then beginning quotes so that if I type

      if (flag)
          string str = "There was an error in the output, you must first \[enter\]type 't', then the input.";
      

      , the output is thus:

      if (flag)
          string str = "There was an error in the output, you must first " + 
          "type 't', then the input";
      

      Is there an analogous feature in Visual Studio. Now, I have to type the end-quotes, the plus sign, enter, and the beginning quotes, and it gives me the red-squiggly the whole time. Thanks for your responses. In Christ, Aaron Laws http://ProCure.com/

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      Hi, no, I don't think there is. FWIW: your example doesn't make sense, str is unused and out of scope right away. :)

      Luc Pattyn


      I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages


      Local announcement (Antwerp region): Lange Wapper? 59.24% waren verstandig genoeg om NEEN te stemmen; bye bye viaduct.


      L 1 Reply Last reply
      0
      • L Luc Pattyn

        Hi, no, I don't think there is. FWIW: your example doesn't make sense, str is unused and out of scope right away. :)

        Luc Pattyn


        I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages


        Local announcement (Antwerp region): Lange Wapper? 59.24% waren verstandig genoeg om NEEN te stemmen; bye bye viaduct.


        L Offline
        L Offline
        LimitedAtonement
        wrote on last edited by
        #3

        Dear Mr. Pattyn, Yeah, you HAVE to put things like this in your code all over the place, so that you can put out another version in a few months which is `optimized.' You must be novice. ;-) In Christ, Aaron Laws

        D L L 3 Replies Last reply
        0
        • L LimitedAtonement

          Dear Mr. Pattyn, Yeah, you HAVE to put things like this in your code all over the place, so that you can put out another version in a few months which is `optimized.' You must be novice. ;-) In Christ, Aaron Laws

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #4

          No, he's no novice. What he commented on was your example. You declared a variable in the True side of teh if statement and didn't use it for anything. He knows full well that the quotes and + sign is required as described in your question. No, there is no equivilent in Visual Studio. But, it sounds like a perfect opportunity for you to create a plugin to do it.

          A guide to posting questions on CodeProject[^]
          Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
               2006, 2007, 2008
          But no longer in 2009...

          1 Reply Last reply
          0
          • L LimitedAtonement

            Dear Mr. Pattyn, Yeah, you HAVE to put things like this in your code all over the place, so that you can put out another version in a few months which is `optimized.' You must be novice. ;-) In Christ, Aaron Laws

            L Offline
            L Offline
            Luc Pattyn
            wrote on last edited by
            #5

            LimitedAtonement wrote:

            You must be novice

            Yes I'm learning new stuff every day. :laugh:

            Luc Pattyn


            I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages


            Local announcement (Antwerp region): Lange Wapper? 59.24% waren verstandig genoeg om NEEN te stemmen; bye bye viaduct.


            1 Reply Last reply
            0
            • L LimitedAtonement

              Dear Mr. Pattyn, Yeah, you HAVE to put things like this in your code all over the place, so that you can put out another version in a few months which is `optimized.' You must be novice. ;-) In Christ, Aaron Laws

              L Offline
              L Offline
              LimitedAtonement
              wrote on last edited by
              #6

              Dear Sirs, Oh!! I was wondering why my message didn't seem to hit its mark properly -- I meant to put a wink in there after `novice'!! I'm just kidding! Now I see that the wink was edited out...how do I get a little smiley face in the text? Sorry if this was taken wrong.

              In Christ, Aaron Laws http://ProCure.com

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups