Forum Visual Studio
We are excited to announce that the Xamarin Forums are moving to the new Microsoft Q&A experience. Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

We encourage you to head over to Microsoft Q&A for .NET for posting new questions and get involved today.

System.Diagnostics.Debug.WriteLine Not Working

njsokalskinjsokalski Member ✭✭✭

I am attempting to use the following statement in my Xamarin.Forms/Android/C# app:
System.Diagnostics.Debug.WriteLine("Some String");
This code should output the parameter (in this case "Some String") to the Immediate window in Visual Studio 2019. I know the code is reached because I have placed a Breakpoint. I have used this statement many times before in code I have written for UWP/VB apps. Is this statement not available in Xamarin.Forms? I am relatively new to Xamarin.Forms & C#, but I figured this was a simple enough statement that it should still work. Any ideas? Thanks.

Best Answer


  • njsokalskinjsokalski Member ✭✭✭

    Using the Output window is working, so I guess that's good enough for now, but I thought that the "Redirect all Output Window text to the Immediate Window" option would cause it to display in the Immediate window (that's what it did for my UWP projects). But I guess the Output window is good enough for now. Thanks!

Sign In or Register to comment.