# FileName Property (DAVAdapter Object)

Returns or sets a string that represents the file name that the current Microsoft Office InfoPath 2003 form will be given when the form is submitted by the DAVAdapter object.

expression.FileName

expression Required. An expression that returns a reference to the DAVAdapter object

## Security Level

2: Can be accessed only by forms running in the same domain as the currently open form, or by forms that have been granted cross-domain permissions.

## Remarks

Note This object model member is not supported when the Disable Service Pack features option on the Advanced tab of the Options dialog box in InfoPath is selected or when Microsoft Office 2003 Service Pack 1 or later is not installed. Any form that implements this object model member in its code will generate an error message if it is opened in InfoPath when service pack features are disabled or unavailable.

## Remarks

The ".xml" file name extension will be appended to the string if it is not already included. If the FileName property is set to null, the form is given the name "Form.xml" when it is submitted.

## Example

The following example shows how to use the FileName property of an instance of the DAVAdapter object to set the file name of the submitted form:

`objDAVAdapter. FileName = strName + "–" + strDate + ".xml";`

©2003-2004 Microsoft Corporation. All rights reserved. Permission to copy, display and distribute this document is available at: http://msdn.microsoft.com/library/en-us/odcXMLRef/html/odcXMLRefLegalNotice.asp