Partager via


IVsCodeWindowEx.Initialize Method

Customizes some of the behavior of a code window, such as making the window read-only, hiding the dropdown bar and splitter, and provide auxiliary user context.

Namespace:  Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop.8.0 (in Microsoft.VisualStudio.TextManager.Interop.8.0.dll)

Syntax

'Declaration
Function Initialize ( _
    grfCodeWindowBehaviorFlags As UInteger, _
    usageAuxUserContext As VSUSERCONTEXTATTRIBUTEUSAGE, _
    szNameAuxUserContext As String, _
    szValueAuxUserContext As String, _
    InitViewFlags As UInteger, _
    pInitView As INITVIEW() _
) As Integer
int Initialize(
    uint grfCodeWindowBehaviorFlags,
    VSUSERCONTEXTATTRIBUTEUSAGE usageAuxUserContext,
    string szNameAuxUserContext,
    string szValueAuxUserContext,
    uint InitViewFlags,
    INITVIEW[] pInitView
)
int Initialize(
    [InAttribute] unsigned int grfCodeWindowBehaviorFlags, 
    [InAttribute] VSUSERCONTEXTATTRIBUTEUSAGE usageAuxUserContext, 
    [InAttribute] String^ szNameAuxUserContext, 
    [InAttribute] String^ szValueAuxUserContext, 
    [InAttribute] unsigned int InitViewFlags, 
    [InAttribute] array<INITVIEW>^ pInitView
)
abstract Initialize : 
        grfCodeWindowBehaviorFlags:uint32 * 
        usageAuxUserContext:VSUSERCONTEXTATTRIBUTEUSAGE * 
        szNameAuxUserContext:string * 
        szValueAuxUserContext:string * 
        InitViewFlags:uint32 * 
        pInitView:INITVIEW[] -> int
function Initialize(
    grfCodeWindowBehaviorFlags : uint, 
    usageAuxUserContext : VSUSERCONTEXTATTRIBUTEUSAGE, 
    szNameAuxUserContext : String, 
    szValueAuxUserContext : String, 
    InitViewFlags : uint, 
    pInitView : INITVIEW[]
) : int

Parameters

  • grfCodeWindowBehaviorFlags
    Type: System.UInt32

    [in] Enumeration value which determines the behavior of the code window. Possible values are: CWB _DEFAULT, CWB_DISABLEDROPDOWNBAR, or CWB_DISABLESPLITTER.

  • szNameAuxUserContext
    Type: System.String

    [in] The name of the auxiliary user context.

  • szValueAuxUserContext
    Type: System.String

    [in] The value of the auxiliary user context.

Return Value

Type: System.Int32
Returns S_OK if the method succeeds.

Remarks

This method should be called before calling SetBuffer.

.NET Framework Security

See Also

Reference

IVsCodeWindowEx Interface

Microsoft.VisualStudio.TextManager.Interop Namespace