Displaying A Long String

gemma-the-husky

Super Moderator
Staff member
Local time
Today, 07:35
Joined
Sep 12, 2006
Messages
16,024
I have tried to read in a text file, and display it in a text box

according to Access help (2002XP as it happens) a variable length string can be 2billion chars

I am holding the string in a global variable, type string
I then assign it to a text box on a form, which opens ok, showing the text - but when I scroll down with vertical scroll bar the following happens

- a file of 64K+ chars is OK
- a file of 240K chars is causing access to crash part of the way down, with an insufficient resources message

- i am loading the string by doing a readall on a textstream object, and I know the help for that warns about system resources, but it reads the string ok, and afterwards, i then set the scripting variables to "nothing"

I can open it by shelling with notepad, but I really wanted it readonly

Any thoughts?
 
Gemma,

The string variable can hold that much, but I think a TextBox is limited to
64K (65,535) characters.

Wayne
 
is there no way to display a large text file (string) then within access
 
Could you not break it into several overlapping text boxes with Next and Previous buttons to control the boxes visibility?

Bob
 
a) multiple text boxes would look worse i think, bob
b) a memo is defginitely only 64K characters, george

i think i will stick with using notepad
 

Users who are viewing this thread

Back
Top Bottom