Udostępnij za pośrednictwem


IVsWindowPane.SaveViewState(IStream) Method

Definition

Saves a view state of a document window.

public:
 int SaveViewState(Microsoft::VisualStudio::OLE::Interop::IStream ^ pStream);
public:
 int SaveViewState(Microsoft::VisualStudio::OLE::Interop::IStream ^ pStream);
int SaveViewState(Microsoft::VisualStudio::OLE::Interop::IStream const & pStream);
public int SaveViewState (Microsoft.VisualStudio.OLE.Interop.IStream pStream);
abstract member SaveViewState : Microsoft.VisualStudio.OLE.Interop.IStream -> int
Public Function SaveViewState (pStream As IStream) As Integer

Parameters

pStream
IStream

[in] Pointer to the IStream interface of the view state to save.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsWindowPane::SaveViewState(  
   [in] IStream *pstream  
);  

SaveViewState is called when the window pane in question is associated with a document view object. SaveViewState is not called for tool windows. If you want to implement persistence for your tool windows, you have to provide the implementation yourself. The Visual Studio environment only persists the tool window layout.

Applies to