I have a txt file that I imported and need to parse out so that it can be usable. I built a query, but needs further processing to generate the table, so have tried using a recordset, it works, except that if the data are longer than 255 it truncates. I looked through various posts and tried suggestions as being sure the underlying table is long text (memo in older versions). Another suggestion was to save the data in a table and use that as the recordset rather than a query, that way it is not using any functions that I used in the query such as left, mid, iif etc. This did not work either. I also tried file system object reading the text file directly line by line. If I debug.print, I see the full string of text, but the table does not get the full string, despite the data type of the field set to long text.
sample string
[tt]
1. This is the first line and is 295 chars wide
A. This is the second line
B. This is the third line
*C. This is the fourth line
D. This is the fifth line
2. This is the sixth line
[/tt]
table result should be something like this:
code snippet
sample string
[tt]
1. This is the first line and is 295 chars wide
A. This is the second line
B. This is the third line
*C. This is the fourth line
D. This is the fifth line
2. This is the sixth line
[/tt]
table result should be something like this:
Code:
qno qtext response rtext correct <==field name
number long text short text long text yes/no <==Data type
1 This is the first line and is 295 chars wide A This is the second line 0
1 This is the first line and is 295 chars wide B This is the third line 0
1 This is the first line and is 295 chars wide C This is the fourth line -1
1 This is the first line and is 295 chars wide D This is the fifth line 0
code snippet
Code:
rs.AddNew
rs!qno= rsList!Questionno
rs!qText = rsList!Text1
rs!response = rsList!type
rs!rtext = rsList!Text1
rs!correct = rsList!correct
rs.Update
rsList.MoveNext