I have searched the forums and looked at the demos and still don't have the answer.
I have a DBSRichViewEdit object which I assigned a RVStyle object (RVStyle1). I tried adding a style at design time and at run time using RVStyle1.TextStyles.Add. No matter what I do, the text styles are the default styles and any reference to my inserted styles gives a red background and white letters in the default font.
All I want to do is change the background and text color to black and white respectively.
The TextStyles.Count includes the added styles. Default is 5. With the one I added at design time it is 6. And, when I add another at run time it is 7.
I even tried adding the design time style in the 3rd position and it still has the properties of the default 3rd style.
You would think this would be easy!
RVStyle giving wrong color
-
- Site Admin
- Posts: 17569
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
I tried reproducing this problem with a fresh project lastnight and the styles worked as intended.
The form with the problem (actually forms now since I have two) is based on the ScaleRichView ActionTest demo (ActionTestD2009) Unit3 form. I copied this form, removed a few controls I didn't need and started customizing from there. I added an RVStyle control, linked it to the SRichViewEdit (now a DBSRichViewEdit), and added a text style. I tried adding a text style at design time and adding one in the Form.OnCreate event. Neither had any impact on the default styles. Any text styles beyond index 5 were red background with white letters. I assume this is the default for undefined styles.
This problem occurrs even it I just open the Query with an inserted blank dataset. I would assume there would not be any style information to replace the styles in the RVStyle object. I only interact with a databse using RTF spec and don't use files from the file system other than to save PDF's.
I'm sure it's just a property setting I've got wrong. But, I've been working 24 hours a day for the last 4 days and I just finished a demo meeting I've been getting ready for, so I'm going to take a break and pick it up in the morning (Houston time - GMT-6).
Thanks for putting up with my barrage of questions over the last few days.
The form with the problem (actually forms now since I have two) is based on the ScaleRichView ActionTest demo (ActionTestD2009) Unit3 form. I copied this form, removed a few controls I didn't need and started customizing from there. I added an RVStyle control, linked it to the SRichViewEdit (now a DBSRichViewEdit), and added a text style. I tried adding a text style at design time and adding one in the Form.OnCreate event. Neither had any impact on the default styles. Any text styles beyond index 5 were red background with white letters. I assume this is the default for undefined styles.
This problem occurrs even it I just open the Query with an inserted blank dataset. I would assume there would not be any style information to replace the styles in the RVStyle object. I only interact with a databse using RTF spec and don't use files from the file system other than to save PDF's.
I'm sure it's just a property setting I've got wrong. But, I've been working 24 hours a day for the last 4 days and I just finished a demo meeting I've been getting ready for, so I'm going to take a break and pick it up in the morning (Houston time - GMT-6).
Thanks for putting up with my barrage of questions over the last few days.
-
- Site Admin
- Posts: 17569
- Joined: Sat Aug 27, 2005 10:28 am
- Contact: