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. The Lounge
  3. VS 2017: when you wonder why your Console.Writexxxx do nothing

VS 2017: when you wonder why your Console.Writexxxx do nothing

Scheduled Pinned Locked Moved The Lounge
delphivisual-studiocomlearning
19 Posts 8 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.
  • B BillWoodruff

    Try this: [^]. Been a while since I actually came up with a solution on my ownsome I had not seen on CP or StackO'Flow. That does mean, of course, that you should treat the hack like the arrival of an unexpected package post-marked Chernobyl. cheers, Bill

    «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

    P Offline
    P Offline
    Pete OHanlon
    wrote on last edited by
    #9

    Console.WriteLine[^] has never written to the Output window (which is a trace listener), it writes to the console instead. What you are doing is just System.Diagnostics.Debug.WriteLine[^] which is no different to earlier versions.

    This space for rent

    B 1 Reply Last reply
    0
    • P Pete OHanlon

      Console.WriteLine[^] has never written to the Output window (which is a trace listener), it writes to the console instead. What you are doing is just System.Diagnostics.Debug.WriteLine[^] which is no different to earlier versions.

      This space for rent

      B Offline
      B Offline
      BillWoodruff
      wrote on last edited by
      #10

      You are incorrect: this is an issue, an annoying disruption of long-standing behavior by VS. See my reply to Duncan Jones here for a link to a statement by a VS Team Member acknowledging the issue. In VS WinForms (old, and new) there is a specific window named 'Output, and that's where the Console output goes when running in Debug mode ... unless you have changed the VS UI of that window, or the Project settings compiler directives, or, your code re-directs standard out. I may be half-blind now, but I don't make these things uo :)

      «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

      1 Reply Last reply
      0
      • D Duncan Edwards Jones

        If the DEBUG compile time constant is not set, that won't do anything though?

        B Offline
        B Offline
        BillWoodruff
        wrote on last edited by
        #11

        Hi Duncan, In the "stock" VS2017 WinForm app I am using, both DEBUG and TRACE are checked in Project/Properties/Build. And, Console.WriteXXX does nothing. Evidently, this is a "feature." On February 21, a VS Team Member wrote: [^]

        Quote:

        Thank you for your feedback! The Visual Studio team has determined that this issue will not be addressed in the upcoming release. We will continue to evaluate it for future releases. Please refer to the workaround posted above. Thank you for helping us build a better Visual Studio!

        «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

        D 1 Reply Last reply
        0
        • B BillWoodruff

          Hi Duncan, In the "stock" VS2017 WinForm app I am using, both DEBUG and TRACE are checked in Project/Properties/Build. And, Console.WriteXXX does nothing. Evidently, this is a "feature." On February 21, a VS Team Member wrote: [^]

          Quote:

          Thank you for your feedback! The Visual Studio team has determined that this issue will not be addressed in the upcoming release. We will continue to evaluate it for future releases. Please refer to the workaround posted above. Thank you for helping us build a better Visual Studio!

          «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

          D Offline
          D Offline
          Duncan Edwards Jones
          wrote on last edited by
          #12

          I've had a quick look at the sourcecode [^] and it appears that there is a registry key that (I kid you not) is called ConsoleSpewToDebugger - maybe try setting that?

          B 1 Reply Last reply
          0
          • D Duncan Edwards Jones

            I've had a quick look at the sourcecode [^] and it appears that there is a registry key that (I kid you not) is called ConsoleSpewToDebugger - maybe try setting that?

            B Offline
            B Offline
            BillWoodruff
            wrote on last edited by
            #13

            Duncan Edwards Jones wrote:

            registry key that (I kid you not) is called ConsoleSpewToDebugger

            Wow, I can't afford the HazMat Suit necessary to mess with that one :)

            «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

            1 Reply Last reply
            0
            • J Joan M

              Sorry, I was only trying to tell that the author has written wtite and not write on the subject. I guess that my super-English and the lack of the joke icon has made it... Anyway, he should improve the title. :thumbsup:

              www.robotecnik.com[^] - robots, CNC and PLC programming

              B Offline
              B Offline
              BillWoodruff
              wrote on last edited by
              #14

              Well, gosh, why should you leave helpful feedback on the content where it is posted ... when you can increase the static on the Lounge, and revel in someone else making a mistake typing ?

              «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

              J 1 Reply Last reply
              0
              • B BillWoodruff

                Well, gosh, why should you leave helpful feedback on the content where it is posted ... when you can increase the static on the Lounge, and revel in someone else making a mistake typing ?

                «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

                J Offline
                J Offline
                Joan M
                wrote on last edited by
                #15

                Oops Bill, I thought I was telling it to you at the beginning... and then I did not remember to post it again... X| My fault.

                www.robotecnik.com[^] - robots, CNC and PLC programming

                https://www.robotecnik.com freelance robots, PLC and CNC programmer.

                B 1 Reply Last reply
                0
                • W W Balboos GHB

                  I don't care what they say about you - I like your Dragon avatar.* * My being born in a Dragon year doesn't have too much to do with that, I think

                  Ravings en masse^

                  "The difference between genius and stupidity is that genius has its limits." - Albert Einstein

                  "If you are searching for perfection in others, then you seek disappointment. If you are seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010

                  B Offline
                  B Offline
                  BillWoodruff
                  wrote on last edited by
                  #16

                  Hi, Balboos, that avatar (photo by me, manipulated in Photohop) is the ground-level stucco/cement finial of a decorative stairway leading into the Dhamma Hall at Wat Buppharam in Chiang Mai. Usually these stairway decorations are makara, a chimeric creature, a composite of creatures, often a mix of sea/river-land-air creatures. Usually the creature at the end of the makara will be some form of Naga (water serpent, Thai: phayanaak). The style of this one does appear to be a Chinese dragon. Here's a photo (not by me) in context: [^] While the origins of Wat Buppharam date to 1497CE, this decorative sculpture, and the building it connects to, are certainly from the modern era. cheers, Bill

                  «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

                  M 1 Reply Last reply
                  0
                  • J Joan M

                    Oops Bill, I thought I was telling it to you at the beginning... and then I did not remember to post it again... X| My fault.

                    www.robotecnik.com[^] - robots, CNC and PLC programming

                    B Offline
                    B Offline
                    BillWoodruff
                    wrote on last edited by
                    #17

                    Don't worry, I still love you. cheers, Bill

                    «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

                    J 1 Reply Last reply
                    0
                    • B BillWoodruff

                      Hi, Balboos, that avatar (photo by me, manipulated in Photohop) is the ground-level stucco/cement finial of a decorative stairway leading into the Dhamma Hall at Wat Buppharam in Chiang Mai. Usually these stairway decorations are makara, a chimeric creature, a composite of creatures, often a mix of sea/river-land-air creatures. Usually the creature at the end of the makara will be some form of Naga (water serpent, Thai: phayanaak). The style of this one does appear to be a Chinese dragon. Here's a photo (not by me) in context: [^] While the origins of Wat Buppharam date to 1497CE, this decorative sculpture, and the building it connects to, are certainly from the modern era. cheers, Bill

                      «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

                      M Offline
                      M Offline
                      Mike EEEE
                      wrote on last edited by
                      #18

                      Way random question here, but did you used to live in the Seattle area, circa 2000? I used to work in a company with a Bill Woodruff who was supposed to move to Thailand (I believe... it was somewhere very Eastern). Pretty crazy if you are him. Pretty crazy if not in any case, LOL. FWIW I happened across your profile while reading a comment in an article about Sprache: Sprache.Calc: building yet another expression evaluator[^]

                      1 Reply Last reply
                      0
                      • B BillWoodruff

                        Don't worry, I still love you. cheers, Bill

                        «When I consider my brief span of life, swallowed up in an eternity before and after, the little space I fill, and even can see, engulfed in the infinite immensity of spaces of which I am ignorant, and which know me not, I am frightened, and am astonished at being here rather than there; for there is no reason why here rather than there, now rather than then.» Blaise Pascal

                        J Offline
                        J Offline
                        Joan M
                        wrote on last edited by
                        #19

                        :cool::thumbsup:

                        www.robotecnik.com[^] - robots, CNC and PLC programming

                        https://www.robotecnik.com freelance robots, PLC and CNC programmer.

                        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