C#Console.Title作为字符串? [英] C# Console.Title as a string?

查看:230
本文介绍了C#Console.Title作为字符串?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

此:

string player1name = Console.ReadLine();
string player2name = Console.ReadLine();
Console.Title = ???


如何在标题中添加玩家名称?
我试过了:


How do I put the player names in the title?
I tried:

Console.Title = "{0}  vs. {1}", player1name, player2name;


等等等等,但是什么都不起作用,有什么帮助吗?


etc. etc. but nothing works, any help?

推荐答案

HI,
请检查一下.
http://www.dotnetperls.com/console-title [

Please check this.
http://www.dotnetperls.com/console-title[^]


这篇关于C#Console.Title作为字符串?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆