Compartilhar via


VCLanguageManager.ValidateFileName(String, vsCMValidateFileExtension) Method

Definition

Determines if the specified file name is a valid C++ file name.

bool ValidateFileName(std::wstring const & bstrFile, Microsoft::VisualStudio::VCCodeModel::vsCMValidateFileExtension eFileType = Microsoft.VisualStudio.VCCodeModel.vsCMValidateFileExtension.vsCMValidateFileExtCpp);
[System.Runtime.InteropServices.DispId(6)]
public bool ValidateFileName (string bstrFile, Microsoft.VisualStudio.VCCodeModel.vsCMValidateFileExtension eFileType = Microsoft.VisualStudio.VCCodeModel.vsCMValidateFileExtension.vsCMValidateFileExtCpp);
[<System.Runtime.InteropServices.DispId(6)>]
abstract member ValidateFileName : string * Microsoft.VisualStudio.VCCodeModel.vsCMValidateFileExtension -> bool
Public Function ValidateFileName (bstrFile As String, Optional eFileType As vsCMValidateFileExtension = Microsoft.VisualStudio.VCCodeModel.vsCMValidateFileExtension.vsCMValidateFileExtCpp) As Boolean

Parameters

bstrFile
String

Required. The file name to be validated.

eFileType
vsCMValidateFileExtension

Optional. A vsCMValidateFileExtension value representing the valid file type.

Returns

true if the specified file name is a valid C++ file name; otherwise, false.

Attributes

Applies to