I have this function to TRIM all varchar fields in a cursor: FUNCTION CTOV(tcCursor As String) As VOID ********************************************************************************************************************************* * Date : 19/06/2014, 11:13:27 * Author : Laurie Alvey * Description: Replace all varchar columns with their TRIMmed contents * Parameters : Name of the open cursor on which to operate. - * ********************************************************************************************************************************* LOCAL ARRAY laCols[1,18] LOCAL n As Integer, i As Integer, lcFld As String n = AFIELDS(laCols,tcCursor) FOR i = 1 TO n IF laCols[i,2] == "V" lcFld = laCols[i,1] REPLACE (lcFld) WITH ALLTRIM(EVALUATE(lcFld)) ALL ENDIF ENDFOR ENDFUNC && CTOV
Laurie On 14 July 2015 at 12:31, Peter Cushing <[email protected]> wrote: > On 13/07/2015 18:09, Ted Roche wrote: > >> I thought about the TESTMERGE solution, and I do use that in some >> parts of the app, where the client has to interface with some >> dedicated hardware that has *WEIRD* formatting rules, but hadn't >> considered that here. If I can get away with Tracy's solution of >> hacking at _ClipText, I'll probably stick with it. >> >> You could always import the data with wide fields, calculate the maximum > widths, then create a custom cursor and import again. > > Peter > > > > > > This communication is intended for the person or organisation to whom it > is addressed. The contents are confidential and may be protected in law. > Unauthorised use, copying or disclosure of any of it may be unlawful. If > you have received this message in error, please notify us immediately by > telephone or email. > www.whisperingsmith.com > > Whispering Smith Ltd Head Office:61 Great Ducie Street, Manchester M3 1RR. > Tel:0161 831 3700 Fax:0161 831 3715 > London Office:17-19 Foley Street, London W1W 6DW Tel:0207 299 7960 > > [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/CAMvTR9dmnGC=-rrlr+3qw5c3v8k2eror066n+evr4pir3wo...@mail.gmail.com ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

