ScriptAndResultsEditorControl Class

Definition

Base class for all editors that have a script, a splitter below it, and a control below the splitter.

public ref class ScriptAndResultsEditorControl abstract : Microsoft::SqlServer::Management::UI::VSIntegration::Editors::ScriptEditorControl, Microsoft::SqlServer::Management::UI::VSIntegration::Editors::ISqlScriptWindowWithConnection, Microsoft::VisualStudio::Shell::Interop::IVsWindowFrameNotify3
public abstract class ScriptAndResultsEditorControl : Microsoft.SqlServer.Management.UI.VSIntegration.Editors.ScriptEditorControl, Microsoft.SqlServer.Management.UI.VSIntegration.Editors.ISqlScriptWindowWithConnection, Microsoft.VisualStudio.Shell.Interop.IVsWindowFrameNotify3
type ScriptAndResultsEditorControl = class
    inherit ScriptEditorControl
    interface IVsWindowFrameNotify3
    interface ISqlScriptWindowWithConnection
    interface ISqlToolsWindowWithConnectionState
Public MustInherit Class ScriptAndResultsEditorControl
Inherits ScriptEditorControl
Implements ISqlScriptWindowWithConnection, IVsWindowFrameNotify3
Inheritance
Derived
Implements

Remarks

This class defines splitter member as well as set of protected methods that should be used for manipulation with the splitter and controls above/below it.

Fields

buildAction (Inherited from ScriptEditorControl)
fedRootName

Specifies the name of the root federation.

initialFocus (Inherited from ScriptEditorControl)
isCloudDatabase

Determines whether SQL Server Management Studio is currently connected to a SQL Azure server.

isClrProjectFile (Inherited from ScriptEditorControl)
isDacProjectFile (Inherited from ScriptEditorControl)
isFedMemAttrChecked

A Boolean value that indicates whether the federation member attribute is checked.

isProjectDebugging

A Boolean value that indicates whether the project is debugging.

m_connection

Cached connection that is associated with the window.

m_connectionInfoList

Cached connection info that is used in communication with the connection dialog box.

m_connectionToUse

Specifies a connection information that should be applied to the window after it is fully initialized, unless it is stamped with another connection.

m_dtExecBegan

Specifies a member to store at the beginning of script execution.

m_Editor (Inherited from ScriptEditorControl)
m_scriptSplitter

Splitter to horizontally separate script and other elements.

m_serviceProvider (Inherited from ScriptEditorControl)
m_sp (Inherited from ShellWindowPaneUserControl)
m_strOrigMoniker (Inherited from ScriptEditorControl)
m_timeElapsedTimer

Timer for updating properties window with elapsed time during query execution.

menuCommands (Inherited from ShellWindowPaneUserControl)
projectNode (Inherited from ScriptEditorControl)
selectionServiceForProperties (Inherited from ShellWindowPaneUserControl)
shardName

Specifies the shard name.

statusBar

Status bar.

statusBarManager (Inherited from ScriptEditorControl)
sysShardName

Specifies the system shard name.

Properties

BuildAction (Inherited from ScriptEditorControl)
CmdUIGuid (Inherited from ScriptEditorControl)
Connection

Returns parameters in the case where script editor has a current connection.

ConnectionInfoList

Gets connection context for the editor.

CurrentDB

Gets or sets the logical database that is current for the script.

DefaultHelpContext (Inherited from ScriptEditorControl)
DocData (Inherited from ScriptEditorControl)
EditorText (Inherited from ScriptEditorControl)
InitialFocus (Inherited from ScriptEditorControl)
IsAFedMember

Gets or sets a value that indicates whether the current database is a federation member.

IsConnected

Gets or sets whether the editor control is connected.

IsControlUnderSplitterVisible

Gets a Boolean value that specifies how the window will be resized.

IsDebugging

Gets or sets whether the script is being executed.

IsExecuting

Gets or sets whether the script is being executed.

IsFrameActive (Inherited from ScriptEditorControl)
IsScriptEditorActive

Gets a Boolean value that specifies whether the code editor is currently active.

IsSqlCmdMode

Gets or sets the flag that specifies whether SQLCMD mode is set.

IsWithNumberOfRowsOnStatusBar

Gets a Boolean value that specifies whether the status bar contains a panel for number of fetched rows.

LanguageServiceGUID (Inherited from ScriptEditorControl)
NameInPropWindow (Inherited from ShellWindowPaneUserControl)
ScriptEditorContextMenuID (Inherited from ScriptEditorControl)
ShowCurrentResultsBelowSplitter

Gets or sets a Boolean value that specifies whether the results show below splitter or start from the second tab.

SqlCmdVars

Gets or sets a dictionary containing all the variables and their values from sqlcmdvars file in Database projects in Visual Studio.

StatusBarManager (Inherited from ScriptEditorControl)
VsUserContext (Inherited from ScriptEditorControl)

Methods

ChangeConnection()

Called when user wants to reconnect to another server while connected.

ClearCachedValues()

Clears cache values from previous shard operations.

ClosePane() (Inherited from ShellWindowPaneUserControl)
Connect()

Establishes a new LIVE connection for the query window.

CreatePaneWindow(IntPtr, Int32, Int32, Int32, Int32, IntPtr) (Inherited from ShellWindowPaneUserControl)
Disconnect()

Disconnects from server.

DisconnectAll(IWin32Window, Boolean)

Disconnect all windows.

Dispose(Boolean)

Closes the connections and cleans up any resources being used.

Exec(Guid, UInt32, UInt32, IntPtr, IntPtr) (Inherited from ShellWindowPaneUserControl)
FillMenuCommands()

Support menu commands.

GetDefaultSize(SIZE[]) (Inherited from ShellWindowPaneUserControl)
GetFrameCaption(String) (Inherited from ScriptEditorControl)
GetService(Guid) (Inherited from ShellWindowPaneUserControl)
GetService(Type) (Inherited from ShellWindowPaneUserControl)
InitializeSplitter()

Does all splitter-related initialization.

InitializeStatusBar()

Performs status-bar related initialization. Derived classes should override it to add more status bar panels and adjust it.

IsSqlClrProjectFile(IVsTextView) (Inherited from ScriptEditorControl)
LoadViewState(IStream) (Inherited from ScriptEditorControl)
OnDockableChange(Int32) (Inherited from ShellWindowPaneUserControl)
OnExec(Guid, UInt32, UInt32, IntPtr, IntPtr) (Inherited from ShellWindowPaneUserControl)
OnHosted()

Called when sited by Visual Studio. At this time, service providers have already been stored in internal variables, so it is safe to call GetService.

OnMove() (Inherited from ShellWindowPaneUserControl)
OnQueryStatus(Guid, UInt32, OLECMD[], IntPtr) (Inherited from ShellWindowPaneUserControl)
OnResize(EventArgs)

Overrides the WinForms Control base class.

OnShow(Int32) (Inherited from ScriptEditorControl)
OnSize() (Inherited from ShellWindowPaneUserControl)
OnWindowPaneClose() (Inherited from ShellWindowPaneUserControl)
OnWindowPaneCreate() (Inherited from ShellWindowPaneUserControl)
QueryStatus(Guid, UInt32, OLECMD[], IntPtr) (Inherited from ShellWindowPaneUserControl)
SaveViewState(IStream) (Inherited from ScriptEditorControl)
SetConnection(UIConnectionGroupInfo)

Associates a connection context with the script editor.

SetConnection(UIConnectionGroupInfo, IDbConnection)

Enables stamp with live connection.

SetConnection(UIConnectionInfo)

Associate a connection with the script.

SetConnection(UIConnectionInfo, IDbConnection)

Enables stamp used with live connection

SetSite(IServiceProvider) (Inherited from ScriptEditorControl)
ShouldSubscribeToChildrenFocusEvent(Control) (Inherited from ScriptEditorControl)
ShouldTryToReconnectWithCachedCI(UIConnectionInfo)

Determines whether to try to reconnect automatically with the given connection information or to popup a pre-populated connection dialog box without automatically trying to connect.

ShowMessage(String, String, MessageBoxButtons, MessageBoxIcon) (Inherited from ScriptEditorControl)
ToggleResultsControl(Boolean)

Shows or hides the query results control.

TranslateAccelerator(MSG[]) (Inherited from ShellWindowPaneUserControl)
UpdateMenuCommandsStatus(MenuCommand)

Called by the base class to update command status.

UpdatePropWindow(Object) (Inherited from ShellWindowPaneUserControl)

Events

NewConnectionForScript

Event that is fired when a user specifies a new connection for the script from the connection dialog box.

Explicit Interface Implementations

ICustomTypeDescriptor.GetAttributes() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetClassName() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetComponentName() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetConverter() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetDefaultEvent() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetDefaultProperty() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetEditor(Type) (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetEvents() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetEvents(Attribute[]) (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetProperties() (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetProperties(Attribute[]) (Inherited from ShellWindowPaneUserControl)
ICustomTypeDescriptor.GetPropertyOwner(PropertyDescriptor) (Inherited from ShellWindowPaneUserControl)
IVsCodeWindow.Close() (Inherited from ScriptEditorControl)
IVsCodeWindow.GetBuffer(IVsTextLines) (Inherited from ScriptEditorControl)
IVsCodeWindow.GetEditorCaption(READONLYSTATUS, String) (Inherited from ScriptEditorControl)
IVsCodeWindow.GetLastActiveView(IVsTextView) (Inherited from ScriptEditorControl)
IVsCodeWindow.GetPrimaryView(IVsTextView) (Inherited from ScriptEditorControl)
IVsCodeWindow.GetSecondaryView(IVsTextView) (Inherited from ScriptEditorControl)
IVsCodeWindow.GetViewClassID(Guid) (Inherited from ScriptEditorControl)
IVsCodeWindow.SetBaseEditorCaption(String[]) (Inherited from ScriptEditorControl)
IVsCodeWindow.SetBuffer(IVsTextLines) (Inherited from ScriptEditorControl)
IVsCodeWindow.SetViewClassID(Guid) (Inherited from ScriptEditorControl)
IVsFindTarget.Find(String, UInt32, Int32, IVsFindHelper, UInt32) (Inherited from ScriptEditorControl)
IVsFindTarget.GetCapabilities(Boolean[], UInt32[]) (Inherited from ScriptEditorControl)
IVsFindTarget.GetCurrentSpan(TextSpan[]) (Inherited from ScriptEditorControl)
IVsFindTarget.GetFindState(Object) (Inherited from ScriptEditorControl)
IVsFindTarget.GetMatchRect(RECT[]) (Inherited from ScriptEditorControl)
IVsFindTarget.GetProperty(UInt32, Object) (Inherited from ScriptEditorControl)
IVsFindTarget.GetSearchImage(UInt32, IVsTextSpanSet[], IVsTextImage) (Inherited from ScriptEditorControl)
IVsFindTarget.MarkSpan(TextSpan[]) (Inherited from ScriptEditorControl)
IVsFindTarget.NavigateTo(TextSpan[]) (Inherited from ScriptEditorControl)
IVsFindTarget.NotifyFindTarget(UInt32) (Inherited from ScriptEditorControl)
IVsFindTarget.Replace(String, String, UInt32, Int32, IVsFindHelper, Int32) (Inherited from ScriptEditorControl)
IVsFindTarget.SetFindState(Object) (Inherited from ScriptEditorControl)
IVsStatusbarUser.SetInfo() (Inherited from ScriptEditorControl)
IVsWindowFrameNotify3.OnClose(UInt32)
IVsWindowFrameNotify3.OnDockableChange(Int32, Int32, Int32, Int32, Int32)
IVsWindowFrameNotify3.OnMove(Int32, Int32, Int32, Int32)
IVsWindowFrameNotify3.OnSize(Int32, Int32, Int32, Int32)

Applies to