Why
MsgBox ("Document not saved")
rather than
MsgBox "Document not saved"
?
You are certainly going to get an error if one or more of your content controls does not exist.
I do not know what you mean by "the dlgbox needs no open from a specific path." Have the path for saving be a specific path?
The string concatenation looks fine.
Other than that, I would need a bit more documentation. I do not know what the -1 value for .show indicates or why you are testing for it.
You could always have your dialog box get the values from the content controls and if they are empty require input (and then save the input to those controls).
|