MitzEclipse
July 6th, 2001, 01:33 PM
I need help displaying the results of my variables within a text box. Basically, I need to be able to display 3 variables within a text box.
Basically, I can get the output what I want, and the content is perfect, but the alignment is the problem.
I've tried vbTab and vbCrlf and the formatting isn't right.
What I'm trying to do is to take the DATE from DateResults and put it on the SAME LINE as the Results from Domain 1 and Domain 2. Then for the next file, it will display on the next line.
Below is what I have so far. As of right now, the date gets displayed on the top of the text box and the results gets displayed on the bottom -- I want to merge the two.
thanks for your help
'Searching for Date/Time/Year statistics
Dim varWhen As String
varWhen = InStr(1, strContent, 28)
Dim DateResults As String
DateResults = InStr(1, strContent, "Tue")
Dim strWhen, strDateDisplay As String
strWhen = strContent
strDateDisplay = Mid(strContent, DateResults, 28)
'MsgBox strDateDisplay
'Searching for Number of Connections in Domain 1
Dim Results As Integer
Results = InStr(1, strContent, ">")
'MsgBox (Results) (for use when figuring out what character position the > is in)
Dim strVar, strSearch As String
strVar = strContent
strSearch = Mid(strContent, Results + 2, 3)
'Display the results of search for Domain 1
txtResults.Text = strDateDisplay & vbTab & txtResults.Text & Int(strSearch)
'Searching for Number of Connections in Domain 2
Results = InStr(Results + 1, strContent, ">")
strSearch = Int(Mid(strContent, Results + 2, 3))
'Display the results of search for Domain 2
txtResults.Text = strDateDisplay & vbTab & txtResults.Text & vbTab & strSearch & vbCrLf
'Display the last selected file in the txtFileContent textbox
txtFileContent.Text = strContent
Basically, I can get the output what I want, and the content is perfect, but the alignment is the problem.
I've tried vbTab and vbCrlf and the formatting isn't right.
What I'm trying to do is to take the DATE from DateResults and put it on the SAME LINE as the Results from Domain 1 and Domain 2. Then for the next file, it will display on the next line.
Below is what I have so far. As of right now, the date gets displayed on the top of the text box and the results gets displayed on the bottom -- I want to merge the two.
thanks for your help
'Searching for Date/Time/Year statistics
Dim varWhen As String
varWhen = InStr(1, strContent, 28)
Dim DateResults As String
DateResults = InStr(1, strContent, "Tue")
Dim strWhen, strDateDisplay As String
strWhen = strContent
strDateDisplay = Mid(strContent, DateResults, 28)
'MsgBox strDateDisplay
'Searching for Number of Connections in Domain 1
Dim Results As Integer
Results = InStr(1, strContent, ">")
'MsgBox (Results) (for use when figuring out what character position the > is in)
Dim strVar, strSearch As String
strVar = strContent
strSearch = Mid(strContent, Results + 2, 3)
'Display the results of search for Domain 1
txtResults.Text = strDateDisplay & vbTab & txtResults.Text & Int(strSearch)
'Searching for Number of Connections in Domain 2
Results = InStr(Results + 1, strContent, ">")
strSearch = Int(Mid(strContent, Results + 2, 3))
'Display the results of search for Domain 2
txtResults.Text = strDateDisplay & vbTab & txtResults.Text & vbTab & strSearch & vbCrLf
'Display the last selected file in the txtFileContent textbox
txtFileContent.Text = strContent