UI2.SetSaveAsDialogFileName Method
Sets the default file name for a form in the Save As dialog box.
Namespace: Microsoft.Office.Interop.InfoPath
Assembly: Microsoft.Office.Interop.InfoPath (in Microsoft.Office.Interop.InfoPath.dll)
Syntax
'Declaration
Sub SetSaveAsDialogFileName ( _
bstrFileName As String _
)
'Usage
Dim instance As UI2
Dim bstrFileName As String
instance.SetSaveAsDialogFileName(bstrFileName)
void SetSaveAsDialogFileName(
string bstrFileName
)
Parameters
bstrFileName
Type: System.StringThe file name of the form supplied to the Save As dialog box.
Remarks
If the bstrFileName argument is a null reference (Nothing in Visual Basic), "Form" is used as the file name. The SetSaveAsDialogFileName method may be used in conjunction with the SetSaveAsDialogLocation method.
Examples
In the following example, the SetSaveAsDialogFileName method of the UIObject object is used to set the default file name for the "Save As" dialog box:
thisXDocument.UI.SetSaveAsDialogFileName("Status Report.xml");