You're making the assumption that the SaveAs dialog restricts the extension the user can use. Wrong. This only filter the filenames listed in the dialog box. You're code has to make sure the extension is correct, and fix it if it's not, after the user clicks OK and before you open the stream to start writing your data.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
2006, 2007, 2008