如何创建多行输入框

时间:2016-08-02 17:14:46

标签: vb6 inputbox

我正在尝试在VB6中创建一个输入框,我可以在PROMPT中包含空格。我尝试用MSGBOX做同样的事情,但它不会让我做VBCRLF。这就是我要做的事情

This company has more than 1 department.
For Accounting type 1
For Reasearch  type 2

这里的输入框和右边的OK和CANCEL

1 个答案:

答案 0 :(得分:3)

以下代码将显示多行提示字符串:

Dim ret As String
Dim prompt As String

prompt = "This company has more than 1 department." & vbCrLf & _
    "For Accounting type 1" & vbCrLf & _
    "For Reasearch  type 2"


ret = InputBox$(prompt)