Font() and FontSize() errors

Apr 23, 2011 at 7:36 PM

Whenever I try to set the font or font size of a paragraph object using the Font() and FontSize() methods, I get an "object reference not set to an instance of an object" error.

 

Apr 28, 2011 at 9:22 PM
Edited May 2, 2011 at 8:39 PM

You get this error when you set the size before there is any text in the Paragraph (or I was at least)

Make sure you write the text before you try to format it or add error trapping in case there is none (e.g., data driven)