VCCodeDelegate.StartPointOf[vsCMPart, vsCMWhere] Propriété

Définition

Obtient le point de départ de l'objet parent.

public:
 property EnvDTE::TextPoint ^ StartPointOf[EnvDTE::vsCMPart, Microsoft::VisualStudio::VCCodeModel::vsCMWhere] { EnvDTE::TextPoint ^ get(EnvDTE::vsCMPart Part, Microsoft::VisualStudio::VCCodeModel::vsCMWhere Where); };
[System.Runtime.InteropServices.DispId(550)]
public EnvDTE.TextPoint StartPointOf[EnvDTE.vsCMPart Part, Microsoft.VisualStudio.VCCodeModel.vsCMWhere Where = Microsoft.VisualStudio.VCCodeModel.vsCMWhere.vsCMWhereDefault] { [System.Runtime.InteropServices.DispId(550)] [System.Runtime.InteropServices.TypeLibFunc(System.Runtime.InteropServices.TypeLibFuncFlags.FNonBrowsable)] get; }
[<System.Runtime.InteropServices.DispId(550)>]
[<get: System.Runtime.InteropServices.DispId(550)>]
[<get: System.Runtime.InteropServices.TypeLibFunc(System.Runtime.InteropServices.TypeLibFuncFlags.FNonBrowsable)>]
member this.StartPointOf(EnvDTE.vsCMPart * Microsoft.VisualStudio.VCCodeModel.vsCMWhere) : EnvDTE.TextPoint
Public ReadOnly Property StartPointOf(Part As vsCMPart, Optional Where As vsCMWhere = Microsoft.VisualStudio.VCCodeModel.vsCMWhere.vsCMWhereDefault) As TextPoint

Paramètres

Part
vsCMPart

Obligatoire. Valeur vsCMPart indiquant quelle partie de la définition ou de la déclaration doit être utilisée (blocs d'attributs, corps etc.).

Where
vsCMWhere

Facultatif. Valeur vsCMWhere indiquant si l'objet TextPoint est la définition ou la déclaration.

Valeur de propriété

TextPoint

Objet TextPoint.

Attributs

Exemples

Cet exemple ajoute un commentaire au début d’une déclaration d’élément de code.

[Visual Basic]

Sub AddCommentAtBeginning()  
    Dim vcElement As VCCodeElement  
    Dim vcElements As VCCodeElements  
    Dim textPoint As TextPoint  
    vcElements = DTE.Solution.Item(1).CodeModel.Classes  
    vcElement = vcElements.Item(1)  
    textPoint = vcElement.StartPointOf(vsCMPart.vsCMPartWhole)  
    textPoint.CreateEditPoint().Insert("/*Comment*/")  
End Sub  

Remarques

Pour plus d’informations sur la compilation et l’exécution de cet exemple, consultez Comment : compiler un exemple de code pour Visual C++ extensibilité du modèle de code .

S’applique à