Setting Font Style Problem
Trying to set Font style of a dbtext component
in before print. If I use
dbtext.font.name := 'Arial';
dbtext.font.style := [fsbold];
or
dbtext.font.style.fsbold := True;
I get the error message:
Expected: '(' or '[', but found Style
instead.
I can even get the error message:
Expected: '(' or '[', but found '['
instead. (which sort of baffles me ).
What can I do to set the style? Thanks.
(I am using 7.03 Enterprise)
in before print. If I use
dbtext.font.name := 'Arial';
dbtext.font.style := [fsbold];
or
dbtext.font.style.fsbold := True;
I get the error message:
Expected: '(' or '[', but found Style
instead.
I can even get the error message:
Expected: '(' or '[', but found '['
instead. (which sort of baffles me ).
What can I do to set the style? Thanks.
(I am using 7.03 Enterprise)
This discussion has been closed.
Comments
Your second method is the correct way to set the Font.Style at runtime. In
testing, this seems to work fine without any compilation errors on my
machine.
dbText.Font.Style := [fsBold];
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
I just sent you a very simple example which gives me the
error message. Please note that the error also occurs on
my laptop. I am running D7E and RB7.03E. Thanks.
I'm sorry, I was unaware you were using RAP. Since RAP does not support
Delphi Sets, we decided to make each Font.Style into a boolean property to
enable a user to access them. You're RAP code should look something like
the following:
BadgeName.Font.Italic := True;
For more information, please see the RAP FAQ located in the ReportBuilder
help file in the RAP Reference section.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com