Make a shortcut for Console.WriteLine()

前端 未结 14 1484
北恋
北恋 2020-12-23 19:55

I have to type Console.WriteLine() many times in my code. Is it possible to create a shortcut for Console.WriteLine so that I can use it like...

CW=Console.Wr         


        
14条回答
  •  没有蜡笔的小新
    2020-12-23 20:26

    If you have ReSharper you can type out and Enter and the row

    Console.Out.WriteLine("");
    

    will be written.

    In case you want to output a variable there is another live template: outv.

    Console.Out.WriteLine("time = {0}", time);
    

    Here time is a variable which you could select after typing outv.

提交回复
热议问题