Hello,
There are some Folder / FolderAlias properties in different SaveOptions.
The bad behavior is that some of them have Null/Nothing as default while some have String.Empty as default.
Some should get Null/Nothing while some only accept String.Empty.
SvgSaveOptions.ResourcesFolder / SvgSaveOptions.ResourcesFolderAlias : Default is null.
HtmlSaveOptions.ResourceFolder / HtmlSaveOptions.ResourceFolderAlias Default is an empty string. If we assign null: System.ArgumentNullException in Aspose.Words.dll: Value cannot be null.
This causes confusion, IMO, for all properties ending with Folder / FolderAlias that accept a folder as string, internally, you should check if input value: String.IsNullOrWhiteSpace instead of String.IsNullOrEmpty
Beside that, I’m strongly against Null Nothing which was the billion dollar mistake of Sir Tony Hoare:
The Spec# programming system: An overview, by Mike Barnett, K. Rustan M. Leino, and Wolfram Schulte. In CASSIS 2004, LNCS vol. 3362, Springer, 2004, they wrote
1.0 Non-Null Types Many errors in modern programs manifest themselves as null-dereference errors, suggesting the importance of a programming language providing the ability to discriminate between expressions that may evaluate to null and those that are sure not to (for some experimental evidence, see [24, 22]). In fact, we would like to eradicate all null dereference errors.