I am trying to use PDFSharp to change the Font color dynamically, from a combo box.
The XBrushes class has the named colors as its property, however I want to use the combo box to allow the user to choose from the 141 colors available. I does not allow me to subsititute a variable instead of the color, at least the method I have tried, which may be incorrect.
This is the code for the line which gives me the error: 'TxtColorValue is not a member of XBrushes'
If this is impossible does anyone know how I can get the RGB values for all the colors that PDFSharp XBrushes lists?Code:tf.DrawString(Ftext, CFont, XBrushes.TxtColorValue, rect, XStringFormats.TopLeft)
Any help will be appreciated!




Reply With Quote
