Page 1 of 1
Format trouble on character field
Posted: Tue Aug 28, 2001 10:51 am
by FRED_EMMERICH_(Guest)
I am reading a character field from a .dbf file that has embedded carriage returns in it. The application that created the .dbf put them in there and I have no control over it. What I am trying to do is split each of those lines (contained in that character field) into separate lines on my report, center justified. Is there a way to do this with formatting? The center justify is not tunred on in my menus for this field. Best I can get so far is 3 lines left justified and the CR shows as a square at the end of the line.____Thanks,
=> RE: Format trouble on character field
Posted: Tue Aug 28, 2001 3:23 pm
by kfleming
Create a calculated field with the expression:____strrep(fieldx,chr(13),";")____format the field as word wrapped and in Format Record Layout check the box that says begin new line on semicolon.______Kathleen__R&R Support
==> RE: Format trouble on character field
Posted: Tue Aug 28, 2001 3:30 pm
by FRED_EMMERICH_(Guest)
I did as you suggested and I formatted my character field where I replaced the CR with a ;. Now I get a blank line with each of the 3 lines that are created. Also, I can^t get the new field to center justify, that option is grayed out.____Thanks
===> RE: Format trouble on character field
Posted: Wed Aug 29, 2001 11:53 am
by kfleming
Try using:____strrep(fieldx,chr(13),"")____and see if the blank lines disappear.____I can think of no circumstance that would have the center alignment choice greyed out for a character calculated.____Kathleen__R&R Support
====> RE: Format trouble on character field
Posted: Thu Aug 30, 2001 9:00 am
by FRED_EMMERICH_(Guest)
Center align is grayed out when word wrap is turned on.
=====> RE: Format trouble on character field
Posted: Thu Aug 30, 2001 12:41 pm
by kfleming
Right click on the field, choose properties and select Justify.____I just did notice that the Center icon does grey out.______Kathleen__R&R Support
======> RE: Format trouble on character field
Posted: Thu Aug 30, 2001 1:42 pm
by FRED_EMMERICH_(Guest)
I ended up splitting the original character field into 3 separate fields and the center formatting worked okay.