添加连接的字符串之间的断裂线在VB.net [英] Add a break line between concatenated strings in VB.net

查看:204
本文介绍了添加连接的字符串之间的断裂线在VB.net的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图来连接各种功能的输出到一个文本框,但是这一切都用一个biiig线。我怎样才能在变量之间插入断行?我有这样的事情:

I am trying to concatenate the output of various functions into a textbox, but it all comes up in one biiig line. How can I insert break lines in between the variables? I have something like this:

Me.TextBox.text = output1 + output2

和我想有这样的事情:

Me.TextBox.text = output1 + ENTER + output2

任何想法?

谢谢!

推荐答案

的<一个href="http://msdn.microsoft.com/en-us/library/system.environment.newline.aspx"><$c$c>Environment.NewLine只读变量是您要使用的。还有 vbCrLf ,但是这是对传统的目的和的不是的与环境有关的。

The Environment.NewLine read-only variable is what you want to use. There's also vbCrLf, but this is for legacy purposes and not environment-dependant.

请尝试以下操作:

Me.TextBox.Text = output1 + Environment.NewLine + output2

这篇关于添加连接的字符串之间的断裂线在VB.net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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