Sergey,
I tried your wonderful suggestion. It only needed to increase width of the field, right align it and move it to the left.
REPLACE ALL ObjType WITH 8, ;
Fillchar WITH 'C', ;
Offset WITH 1, ;
HPos WITH MAX(0,HPos + Width ;
- ((LEN(ALLTRIM(Expr))) * FONTMETRIC(6,FontFace,FontSize) * 10000 / 96 + 200) ;
Width WITH (LEN(ALLTRIM(Expr))) * FONTMETRIC(6,FontFace,FontSize) * 10000 / 96 + 200 ;
FOR PLATFORM = 'WINDOWS' AND ObjType = 5
Thank you,
Alex
>Hi Alex,
>
>It's a bug. A right aligned label doesn't align properly with other fields when SET REPORTBEHAVIOR 90. It works correctly with SET REPORTBEHAVIOR 80.
>A workaround would be to either SET REPORTBEHAVIOR 80 or convert labels to fields.
>USE report.frx
>REPLACE ALL objtype WITH 8 FOR objtype = 5
>USE
>
>>>
How do you right align in the printed results a title and a number field?
>>>When printed, the number field leaves about one space in the right side, with the result that if you right align title and field in the FRX, they are not right aligned when printed.>>>
>>>I'm not seeing this in a simple example. Can you post more details? I used a simple cursor:
>>>
create cursor x ( ftitle c(10), fnumb n(8,2) )
>>>insert into x values ( 'Bagels',32.45)
>>>insert into x values ( 'Cucumber', 5.23)
>>>
>>>
>>>And then created a simple report with two Field/Expressions of the same width, one above the other. One was Character, right aligned, the other was number, default. In the preview, the contents looked fine, the alignment matched. What else would I have to do to see this behavior you describe?
>>
>>Thanks for the response Colin. I sent you a copy of the frx and dbf involved. Hope that is OK.
>>
>>Also, in my case the title is a label. Would that make any difference?