'Add a TextBox(Text1) To the Form
'The Text1
'.Multiline=True
Private Sub Form_Load()
'Dim strSelect As String
'strSelect = "Insert Into ABC(myDateTime) Values(" & ConvertTimeToSQLServerSQL(Now) & ")"
'Debug.Print strSelect
Dim strSel As String
Dim i As Integer
Dim j As Integer
Dim ChildStr As Integer
ChildStr = 0
strSel = "abcdefg"
With Text1
.Text = ""
' .MultiLine = True
End With
For i = 1 To Len(strSel)
For j = i To Len(strSel)
Debug.Print Mid(strSel, i, j - i + 1)
Text1.Text = Text1.Text + Mid(strSel, i, j - i + 1) & vbCrLf
ChildStr = ChildStr + 1
Next j
Next i
Debug.Print ChildStr
Text1.Text = Text1.Text & ChildStr
End Sub
'The Text1
'.Multiline=True
Private Sub Form_Load()
'Dim strSelect As String
'strSelect = "Insert Into ABC(myDateTime) Values(" & ConvertTimeToSQLServerSQL(Now) & ")"
'Debug.Print strSelect
Dim strSel As String
Dim i As Integer
Dim j As Integer
Dim ChildStr As Integer
ChildStr = 0
strSel = "abcdefg"
With Text1
.Text = ""
' .MultiLine = True
End With
For i = 1 To Len(strSel)
For j = i To Len(strSel)
Debug.Print Mid(strSel, i, j - i + 1)
Text1.Text = Text1.Text + Mid(strSel, i, j - i + 1) & vbCrLf
ChildStr = ChildStr + 1
Next j
Next i
Debug.Print ChildStr
Text1.Text = Text1.Text & ChildStr
End Sub
(Note:the reference of text(.Multiline=True))
a
ab
abc
abcd
abcde
abcdef
abcdefg
b
bc
bcd
bcde
bcdef
bcdefg
c
cd
cde
cdef
cdefg
d
de
def
defg
e
ef
efg
f
fg
g
28