Saves the specified file if it is dirty.
Namespace: Microsoft.VisualStudio.Shell
Assembly: Microsoft.VisualStudio.Shell (in Microsoft.VisualStudio.Shell.dll)
Syntax
'宣言
Public Shared Sub SaveFileIfDirty ( _
site As IServiceProvider, _
fullPath As String _
)
'使用
Dim site As IServiceProvider
Dim fullPath As String
VsShellUtilities.SaveFileIfDirty(site, fullPath)
public static void SaveFileIfDirty(
IServiceProvider site,
string fullPath
)
public:
static void SaveFileIfDirty(
IServiceProvider^ site,
String^ fullPath
)
public static function SaveFileIfDirty(
site : IServiceProvider,
fullPath : String
)
Parameters
site
Type: System.IServiceProvider
fullPath
Type: System.StringThe absolute path of the file.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.