共用方式為


IVsSccProject2.GetSccFiles(UInt32, CALPOLESTR[], CADWORD[]) Method

Definition

This method is called to determine which files should be placed under source control for a given VSITEMID within this hierarchy.

public:
 int GetSccFiles(System::UInt32 itemid, cli::array <Microsoft::VisualStudio::OLE::Interop::CALPOLESTR> ^ pCaStringsOut, cli::array <Microsoft::VisualStudio::OLE::Interop::CADWORD> ^ pCaFlagsOut);
int GetSccFiles(unsigned int itemid, std::Array <Microsoft::VisualStudio::OLE::Interop::CALPOLESTR> const & pCaStringsOut, std::Array <Microsoft::VisualStudio::OLE::Interop::CADWORD> const & pCaFlagsOut);
public int GetSccFiles (uint itemid, Microsoft.VisualStudio.OLE.Interop.CALPOLESTR[] pCaStringsOut, Microsoft.VisualStudio.OLE.Interop.CADWORD[] pCaFlagsOut);
abstract member GetSccFiles : uint32 * Microsoft.VisualStudio.OLE.Interop.CALPOLESTR[] * Microsoft.VisualStudio.OLE.Interop.CADWORD[] -> int
Public Function GetSccFiles (itemid As UInteger, pCaStringsOut As CALPOLESTR(), pCaFlagsOut As CADWORD()) As Integer

Parameters

itemid
UInt32

[in] Identifier for the VSITEMID being queried.

pCaStringsOut
CALPOLESTR[]

[out] Pointer to an array of CALPOLESTR strings containing the file names for this item.

pCaFlagsOut
CADWORD[]

[out] Pointer to a CADWORD array of flags stored in DWORDs indicating that some of the files have special behaviors.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.If a project returns E_NOTIMPL, GetMkDocument(UInt32, String) will be called to discover the file associated with the node. If each of a project's nodes refers to a single file, and there are no special files, then a project can safely always return E_NOTIMPL.

Remarks

COM Signature

From ivssccproject2.idl

HRESULT GetSccFiles(  
   [in] VSITEMID itemid,  
   [out] CALPOLESTR *pCaStringsOut,  
   [out] CADWORD *pCaFlagsOut  
);  

If you use GetMkDocument, the flags are assumed to be zero. If pCaFlagsOut->cElems has zero elements, the flags are assumed to be zero. If you do not have any files under source control, zero files should be returned because GetSccFiles serves no other purpose.

If the flag SFF_HasSpecialFiles is set for any of the files associated with the node, GetSccSpecialFiles will be called for those files.

The source file flags (SFF) have two settings:

  • SFF_NoFlags = 0 indicates that there are no special files associated with the node.

  • SFF_HasSpecialFiles = 1 (or nonzero) indicates that there are special files associated with the node.

Special files are hidden files that underlie the normal files visible in Solution Explorer and in the Check In and Check Out dialog boxes.

Applies to