diff --git a/src/Microsoft.DotNet.Wpf/src/PresentationFramework/Microsoft/Win32/FileDialog.cs b/src/Microsoft.DotNet.Wpf/src/PresentationFramework/Microsoft/Win32/FileDialog.cs
index 553e3c6f125..4abd347685f 100644
--- a/src/Microsoft.DotNet.Wpf/src/PresentationFramework/Microsoft/Win32/FileDialog.cs
+++ b/src/Microsoft.DotNet.Wpf/src/PresentationFramework/Microsoft/Win32/FileDialog.cs
@@ -190,6 +190,22 @@ public bool CheckPathExists
}
}
+ ///
+ /// The file is not created before the dialog box is closed. This flag should be specified if the application saves the file on a create-nonmodify network share. When an application specifies this flag, the library does not check for write protection, a full disk, an open drive door, or network protection. Applications using this flag must perform file operations carefully, because a file cannot be reopened once it is closed.
+ ///
+ public bool NoTestFileCreate
+ {
+ get
+ {
+ return GetOption(NativeMethods.OFN_NOTESTFILECREATE);
+ }
+ set
+ {
+
+ SetOption(NativeMethods.OFN_NOTESTFILECREATE, value);
+ }
+ }
+
///
/// The AddExtension property attempts to determine the appropriate extension
/// by using the selected filter. The DefaultExt property serves as a fallback -
diff --git a/src/Microsoft.DotNet.Wpf/src/Shared/MS/Win32/NativeMethodsCLR.cs b/src/Microsoft.DotNet.Wpf/src/Shared/MS/Win32/NativeMethodsCLR.cs
index e3f03b5f348..156303878d4 100644
--- a/src/Microsoft.DotNet.Wpf/src/Shared/MS/Win32/NativeMethodsCLR.cs
+++ b/src/Microsoft.DotNet.Wpf/src/Shared/MS/Win32/NativeMethodsCLR.cs
@@ -1411,7 +1411,8 @@ public const int
OFN_EXPLORER = 0x00080000,
OFN_NODEREFERENCELINKS = 0x00100000,
OFN_ENABLESIZING = 0x00800000,
- OFN_USESHELLITEM = 0x01000000;
+ OFN_USESHELLITEM = 0x01000000,
+ OFN_NOTESTFILECREATE = 0x00010000;
#if never
public const int OLEIVERB_PRIMARY = 0,