G
Guest
I have a .dat file that has both regular text and tab delimited columns. I
have been using Infile.readline and then InStr function with code like this
to import the regular text not in a column format.
Do Until strsampleID = "Sample ID"
strsampleID = Infile.readline
If InStr(strsampleID, "Sample ID") Then
startpos = InStr(strsampleID, ":")
sampleID = Trim(Mid(strsampleID, startpos + 1, 13))
reslab = Trim(Mid(strsampleID, startpos + 31, 4))
expdate = Trim(Mid(strsampleID, startpos + 60, 14))
Exit Do
that all works fine to get the data and then i have more code to put into
the appropriate tables.
I am not sure how to write the code for the next part. It looks like this
and it is tab delimited between the columns:
CT RN CCC RT
1 1 0.00 4.5666
24 3 222.56 66.444
306 2 33.33 0.0000
1111 4 2.333 229.999
I don't know how to tell it what position in the line to start from to get
the data into the variable and then into the table. Any help would be
appreciated. Thanks.
Michele
have been using Infile.readline and then InStr function with code like this
to import the regular text not in a column format.
Do Until strsampleID = "Sample ID"
strsampleID = Infile.readline
If InStr(strsampleID, "Sample ID") Then
startpos = InStr(strsampleID, ":")
sampleID = Trim(Mid(strsampleID, startpos + 1, 13))
reslab = Trim(Mid(strsampleID, startpos + 31, 4))
expdate = Trim(Mid(strsampleID, startpos + 60, 14))
Exit Do
that all works fine to get the data and then i have more code to put into
the appropriate tables.
I am not sure how to write the code for the next part. It looks like this
and it is tab delimited between the columns:
CT RN CCC RT
1 1 0.00 4.5666
24 3 222.56 66.444
306 2 33.33 0.0000
1111 4 2.333 229.999
I don't know how to tell it what position in the line to start from to get
the data into the variable and then into the table. Any help would be
appreciated. Thanks.
Michele