Datasheet
27.3.1 Accessibility and conditional formatting
Using the accessibility parameter field in simple formulas, you can provide multiple formats for any
object in a report. If a user chooses "Yes" when prompted by the parameter, the conditional formulas
will ensure that the objects are modified with accessible formatting conventions. If a user chooses "No",
then the report appears without accessible formatting, perhaps in the standard company template.
For accessible text formatting, you can follow the guidelines suggested by this section and by the W3C,
or you can survey your report users to determine the formats that work best for them. After you determine
the formatting options you want to use, you can create conditional formulas that define the options. For
example, you can display all database fields in a large Arial font, in white text on a black background,
with the Can Grow option enabled.
The following procedure creates a conditional formatting formula based on the ?Access parameter field.
The formula increases the font size if the ?Access parameter field is set to "Yes". You can use similar
formulas to change colors, add borders, or enable the Can Grow setting. For complete instructions on
conditionally formatting fields and using the Format Formula Editor, see the
Crystal Reports Online
Help
.
Note:
If text objects are too small to accommodate the enlarged font, you can use a similar conditional
formatting formula to enable the Can Grow setting, which appears on the Common tab of the Format
Editor.
27.3.1.1 To apply accessible settings to font size conditionally
1.
Open the report in the Design tab of Crystal Reports.
2.
In the Details section, right-click the field you want to conditionally format, and select Format Field.
3.
In the Format Editor, click the Font tab.
4.
Click the Formula button that corresponds to the Size list.
The Format Formula Editor opens a new formula named Font Size.
5.
In the Formula text window, type this formula (which uses Crystal Syntax):
if {?Access} = "Yes"
then 20
else 10
This formula ensures that the font size for the currently selected field is increased from 10 point to
20 point when the user chooses to display accessible formatting.
6.
Click Save and close.
7.
Click OK in the Format Editor.
2011-05-16680
Creating Accessible Reports










