Compartir a través de


Debugger.HexInputMode Property

Definition

Gets or sets whether expressions are evaluated in hexadecimal or decimal format.

public:
 property bool HexInputMode { bool get(); void set(bool value); };
public:
 property bool HexInputMode { bool get(); void set(bool value); };
[System.Runtime.InteropServices.DispId(108)]
public bool HexInputMode { [System.Runtime.InteropServices.DispId(108)] get; [System.Runtime.InteropServices.DispId(108)] set; }
[<System.Runtime.InteropServices.DispId(108)>]
[<get: System.Runtime.InteropServices.DispId(108)>]
[<set: System.Runtime.InteropServices.DispId(108)>]
member this.HexInputMode : bool with get, set
Public Property HexInputMode As Boolean

Property Value

true if hexadecimal format, otherwise false.

Attributes

Examples

The following example demonstrates how to use the HexInputMode property.

public static void HexInputMode(DTE dte)  
{  
    // Setup the 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("Hex Input Mode Test");  
    owp.Activate();  

    dte.Debugger.HexInputMode = false;  
    dte.Debugger.HexDisplayMode = true;  
    EnvDTE.Expression exp = dte.Debugger.GetExpression("length", true, 1);  
    owp.OutputString("Value of variable length in hex: " + exp.Value);  

    dte.Debugger.HexInputMode = true;  
    dte.Debugger.HexDisplayMode = false;  
    exp = dte.Debugger.GetExpression("length", true, 1);  
    owp.OutputString("\nValue of variable length in decimal: " + exp.Value);  
}  

Remarks

Use HexInputMode to determine or set whether expressions are evaluated in hexadecimal or decimal format. HexInputMode directly corresponds to the setting in the General, Debugging, Options Dialog Box.

See Expressions in the Debugger for more information.

Applies to