Initializes the document.
Namespace: Microsoft.VisualStudio.Modeling.Shell
Assembly: Microsoft.VisualStudio.Modeling.Sdk.Shell (in Microsoft.VisualStudio.Modeling.Sdk.Shell.dll)
Syntax
'宣言
Public Function InitNew ( _
formatIndex As UInteger _
) As Integer
'使用
Dim instance As DocData
Dim formatIndex As UInteger
Dim returnValue As Integer
returnValue = instance.InitNew(formatIndex)
public int InitNew(
uint formatIndex
)
public:
virtual int InitNew(
unsigned int formatIndex
) sealed
public final function InitNew(
formatIndex : uint
) : int
Parameters
formatIndex
Type: System.UInt32The index of the format that represents the document.
Return Value
Type: System.Int32
S_OK if the method succeeds; otherwise, it returns an error code.
Implements
IPersistFileFormat.InitNew(UInt32)
Remarks
At this time, only single file format is supported.
This method implements the IPersistFileFormat interface.
Permissions
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.