Set RTF2 control alignment default

M

mwg

Mr. Lebans-

I'm trying to set the RTF2 control text alignment control to default to
Justify. I can change it successfully within the control at runtime but to
simplify things for my users, I want the control to default to justify. I
don't see an alignment option in the control's custom property dialog box
and when I try to change the SelAlignment property in the properties, it
won't accept my changes. Am I required to change it in code in the form's
load event perhaps?
 
S

Stephen Lebans

There is no default Alignment per se. You would have to write an RTF control
code string into the RTF formatting for all new records to specify a default
Alignment value. For existing records, the default alignment uses whatever
is the current alignment for the text preceding the current Insertion point.
I guess you could loop through all of your records, Select all of the text,
set the SelAlignment prop as desired, and then continue the loop.

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
M

mwg

The existing records are fine. The users have changed the alignment
properly. I was just trying to take a step out for them. I'll try playing
with the alignment control code string for new records.
Thanks for the input.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top