Textbox control being truncated?

ahdkaw

Registered User.
Local time
Today, 13:43
Joined
Apr 6, 2000
Messages
11
Hi,

I have an Access 2000 report which pulls a memo field from my database and displays it within a textbox control (CanGrow enabled), however I have discovered, much to my dismay, that the field is being truncated to 255 characters.

Now, I have read somewhere that the Report Textbox control can actually store 65k characters, so I can't understand why it is being truncated.

I have checked the source query to see if Jet is truncating the field, but it isn't.

Has anybody any idea as to why the Access Report would be doing this and what would be the solution? I have searched Google but haven't come up with any relevent results. :(

Thanks in advance.
 
After a bit more investigation, I have found something weird...

If I take the original data from the query (ie: tblCategories.Details), then the entire memo is correctly displayed within the textbox.

However, this is no good for me, as I need to remove the carriage returns and line feeds before displaying it in the report. Therefore, the query uses my custom function called 'RemoveCRs'. The syntax in the query is as follows:

CleanDetails: RemoveCRs([tblCategories]![Details])

The function is this:

Function RemoveCRs(sToReplace)
RemoveCRs = Replace(sToReplace, Chr(13) & Chr(10), " ")
End Function

The thing is, in the query results, the CleanDetails field is NOT being truncated, it's only when it's passed to the textbox control in the report. :confused:

Any idea's as to why this is happening? Any alternate solutions?

Thanks again.
 
Last edited:
More researching later...

From what I can tell, this is a bug in Access 2000, as at every point in the processing of the data, it is not truncated. It's only when that data is placed on the report that it becomes truncated.

So, I have only one option left to me. I can explain it better if I describe the whole situation, so here goes.

The details field contains carriage returns for display on our website, but it is also displayed on our price list report which does not require the carriage returns. The internal database exports the details for later import to the website database.

So, I think what I shall do to fix this, is to change the original data replacing the carriage returns with doublespaces. Then upon display on the website, I can then replace the doublespaces with carriage returns. I see no other way... :(
 

Users who are viewing this thread

Back
Top Bottom