Browse box string text alignment
Posted: Thu Mar 21, 2013 4:37 am
I’m trying to show browse box data as a single, read-only, selectable, highlighted line per record, but am having problems with vertical alignment. For example (with no trim functions involved):
FIELDS { ’Test->LastName + Space(10) + Test->FirstName + Space(10) + Test->City’ }
produces something like:
....Smith..........Alan......Los Angeles
....Davidson......Stanley........San Francisco
....Ng.............Art.......Sacramento
when what I'm trying to get is:
....Smith.........Alan...........Los Angeles
....Davidson...Stan..........San Francisco
....Ng.............Art.............Sacramento
(Edit: Sorry - that didn't come out well - spaces got stripped so I inserted dots to try to get the intended spacing; I hope you know what I mean.)
Using DBEdit() in DOS, with fixed-space characters, alignment was easy, but with GUI fonts…
I’ve searched for and tried all sorts of things (StrLen(), Tab(), pixel counts, etc.) but just can’t seem to find a solution, or even which direction to take. If anybody can help me with this, it would be much appreciated. Thanks.
FIELDS { ’Test->LastName + Space(10) + Test->FirstName + Space(10) + Test->City’ }
produces something like:
....Smith..........Alan......Los Angeles
....Davidson......Stanley........San Francisco
....Ng.............Art.......Sacramento
when what I'm trying to get is:
....Smith.........Alan...........Los Angeles
....Davidson...Stan..........San Francisco
....Ng.............Art.............Sacramento
(Edit: Sorry - that didn't come out well - spaces got stripped so I inserted dots to try to get the intended spacing; I hope you know what I mean.)
Using DBEdit() in DOS, with fixed-space characters, alignment was easy, but with GUI fonts…
I’ve searched for and tried all sorts of things (StrLen(), Tab(), pixel counts, etc.) but just can’t seem to find a solution, or even which direction to take. If anybody can help me with this, it would be much appreciated. Thanks.