次の方法で共有


IStorage.OpenStorage Method

Definition

public:
 void OpenStorage(System::String ^ pwcsName, Microsoft::VisualStudio::OLE::Interop::IStorage ^ pstgPriority, System::UInt32 grfMode, IntPtr snbExclude, System::UInt32 reserved, [Runtime::InteropServices::Out] Microsoft::VisualStudio::OLE::Interop::IStorage ^ % ppstg);
public void OpenStorage (string pwcsName, Microsoft.VisualStudio.OLE.Interop.IStorage pstgPriority, uint grfMode, IntPtr snbExclude, uint reserved, out Microsoft.VisualStudio.OLE.Interop.IStorage ppstg);
abstract member OpenStorage : string * Microsoft.VisualStudio.OLE.Interop.IStorage * uint32 * nativeint * uint32 * IStorage -> unit
Public Sub OpenStorage (pwcsName As String, pstgPriority As IStorage, grfMode As UInteger, snbExclude As IntPtr, reserved As UInteger, ByRef ppstg As IStorage)

Parameters

pwcsName
String

A pointer to a wide character null-terminated Unicode string that contains the name of the storage object to open. The 000 through 01f characters, serving as the first character of the stream/storage name, are reserved for use by OLE. This is a compound file restriction, not a structured storage restriction. It is ignored if pstgPriority is non-NULL.

pstgPriority
IStorage

Must be NULL. A non-NULL value will return STG_E_INVALIDPARAMETER.

grfMode
UInt32

Specifies the access mode to use when opening the storage object. For descriptions of the possible values, see STGM Constants. Other modes you choose must at least specify STGM_SHARE_EXCLUSIVE when calling this method.

snbExclude
IntPtr

nativeint

Must be NULL. A non-NULL value will return STG_E_INVALIDPARAMETER.

reserved
UInt32

Reserved for future use; must be zero.

ppstg
IStorage

When successful, pointer to the location of an IStorage pointer to the opened storage object. This parameter is set to NULL if an error occurs.

Applies to