Partager via


Breakpoint2.FileColumn, propriété

Obtient l'emplacement du caractère au sein d'une ligne dans un fichier où le point d'arrêt est défini.

Espace de noms :  EnvDTE80
Assembly :  EnvDTE80 (dans EnvDTE80.dll)

Syntaxe

'Déclaration
ReadOnly Property FileColumn As Integer
int FileColumn { get; }
property int FileColumn {
    int get ();
}
abstract FileColumn : int with get
function get FileColumn () : int

Valeur de propriété

Type : Int32
Entier qui contient l'emplacement du caractère.

Notes

Obtient l'emplacement de caractère (la colonne) au sein d'une ligne dans un fichier où le point d'arrêt est défini. Cette valeur est spécifiée dans la zone Caractère de la boîte de dialogue Fichier, Nouveau point d'arrêt.

Exemples

L'exemple suivant illustre l'utilisation de la propriété FileColumn.

Pour tester cette propriété :

  1. Définissez un point d'arrêt dans l'application cible.

  2. Exécutez le complément.

public static void FileColumn(EnvDTE80.DTE2 dte)
{
    // Setup debug Output window.
    Window w = (Window)dte.Windows.Item(EnvDTE.Constants.vsWindowKindOutput);
    w.Visible = true;
    OutputWindow ow = (OutputWindow)w.Object;
    OutputWindowPane owp = ow.OutputWindowPanes.Add("FileColumn property: ");
    owp.Activate();

    // dte is a reference to the DTE2 object passed to you by the
    // OnConnection method that you implement when you create an Add-in.
    EnvDTE80.Debugger2 debugger = (EnvDTE80.Debugger2)dte.Debugger;
    owp.OutputString("Breakpoint in the file " + debugger.Breakpoints.Item(1).File);
    owp.OutputString(" on line " +
                     debugger.Breakpoints.Item(1).FileLine.ToString() + " column ");
    owp.OutputString(debugger.Breakpoints.Item(1).FileColumn.ToString() + " is ");
    owp.OutputString(debugger.Breakpoints.Item(1).Enabled ? "enabled." : "disabled.");
    owp.OutputString("\nThis breakpoint is in the function: " +
                     debugger.Breakpoints.Item(1).FunctionName);
}

Sécurité .NET Framework

Voir aussi

Référence

Breakpoint2 Interface

EnvDTE80, espace de noms

Autres ressources

Comment : compiler et exécuter les exemples de code du modèle objet Automation