I have a simple “feature” request. I often find myself testing for NULL values before doing a
builder.Writeln() because otherwise Aspose will throw an
ArgumentNullException : Value cannot be null.error.
This test clusters my code, this should be done inside the
Writeln(), etc. functions. I cannot think of any case where I would want Aspose.Words to throw if the value is NULL. If I want to throw, I will do it myself.
I’d much rather write this:
if (obj.Description != null) builder.Writeln(obj.Description);
builder.Writeln(obj.Description ?? "");
everywhere in my code.