Question Export on first 70 characters of Comments

rgreene

Registered User.
Local time
Today, 11:52
Joined
Jan 22, 2002
Messages
168
in my database I have a query running and I'm exporting the fields of this query to a csv file. The export is working good but what I want to do is in my query I have a comments box that when I export I just want to export the first 70 characters of that file. This file is eventually being imported into our mainframe and I'm guessing their side of this can only handle the 70 characters.

1st - How would I do this?
2nd - Where do I put this? in the Code of my Event Procedure or somewhere in my Query or somewhere else..

Here is my code that runs the exports just in case it's needed.

DoCmd.TransferText acExportDelim, , "qryExport", "C:\Documents and Settings\RGreene\Desktop\" & BridgeID & ".txt"

Thanks
Rick
 
Just build a field in your query "qryExport" which has the 70 characters:

CommentsForExport:IIf(Len([FieldNameHere] & "") = 0, "", Left([FieldNameHere], 70))
 

Users who are viewing this thread

Back
Top Bottom