Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/csharp/318.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
C# &引用\";在Internet Explorer 10的ASP:按钮内不工作_C#_Asp.net_Asp.net Mvc 4_Internet Explorer 10 - Fatal编程技术网

C# &引用\";在Internet Explorer 10的ASP:按钮内不工作

C# &引用\";在Internet Explorer 10的ASP:按钮内不工作,c#,asp.net,asp.net-mvc-4,internet-explorer-10,C#,Asp.net,Asp.net Mvc 4,Internet Explorer 10,我在一个按钮上有一些文字,我想在按钮内添加一行新的文字我这样做了: btn.Text = "Find\n Transactions"; 这在InternetExplorer9上可以正常工作,但在InternetExplorer10上不行 我也尝试过environment.newline变体,但没有成功 就用这个: Environment.NewLine(); 像这样: btn.text = "some" + Environment.NewLine() + "text"; 您可以尝试vbCr

我在一个按钮上有一些文字,我想在按钮内添加一行新的文字我这样做了:

btn.Text = "Find\n Transactions";
这在InternetExplorer9上可以正常工作,但在InternetExplorer10上不行

我也尝试过environment.newline变体,但没有成功

就用这个:

Environment.NewLine();
像这样:

btn.text = "some" + Environment.NewLine() + "text";

您可以尝试vbCrLf,当然,如果您使用的是web应用程序,请尝试使用



可能与@walther重复很抱歉,我没有特别说明ASP:BUTTON?另一种方式,您可以尝试使用
ASP.net
LinkButton
,它呈现为
,您可以在其中添加一些html。@Bharadwaj感谢您的建议。
<asp:Button Text="Hello&#010;World" runat="server" ID="cmdHello" />