Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xamarin.Forms - Debug.WriteLine() - where does the output go?

I have a simple Xamarin.Forms project that I'm running in Visual Studio, using an iphone emulator. I have the following code in App.cs:

protected override void OnStart()
{
    Debug.WriteLine("---------- OnStart called!");
}

Where exactly is that supposed to output to? I don't see it in any of the Visual Studio output windows (Build, Build Order, Debug, Xamarin, Xamarin Diagnostics).

like image 323
jbyrd Avatar asked Mar 07 '16 15:03

jbyrd


Video Answer


2 Answers

Using Console.WriteLine() works with Device Log. Also you can filter out all device log with mono-stdout tag.

like image 166
Winzipas Avatar answered Sep 19 '22 12:09

Winzipas


Rider has a plugin called Logcat, when I write

Console.WriteLine("**** Hi mate");

, then I can filter the Logcat window for **** and it will show the Console.WriteLine's

This is in Xamarin Forms, for both iOS and Android

like image 45
Atif Rehman Avatar answered Sep 21 '22 12:09

Atif Rehman