Redigera

Dela via


SharedPropertyGroup.CreateProperty(String, Boolean) Method

Definition

Creates a property with the given name.

public:
 System::EnterpriseServices::SharedProperty ^ CreateProperty(System::String ^ name, [Runtime::InteropServices::Out] bool % fExists);
public System.EnterpriseServices.SharedProperty CreateProperty (string name, out bool fExists);
member this.CreateProperty : string * bool -> System.EnterpriseServices.SharedProperty
Public Function CreateProperty (name As String, ByRef fExists As Boolean) As SharedProperty

Parameters

name
String

The name of the new property.

fExists
Boolean

Determines whether the property exists. Set to true on return if the property exists.

Returns

The requested SharedProperty.

Examples

The following code example shows how to use the CreateProperty method to create a shared property.

// Create a shared property group.
SharedPropertyGroup^ group =
   groupManager->CreatePropertyGroup( "Receipts",  lockMode,  releaseMode,  groupExists );

// Create a shared property.
SharedProperty^ ReceiptNumber;
ReceiptNumber = group->CreateProperty( "ReceiptNumber",  propertyExists );
// Create a shared property group.
SharedPropertyGroup group = groupManager.CreatePropertyGroup("Receipts",
                           ref lockMode, ref releaseMode, out groupExists);
// Create a shared property.
SharedProperty ReceiptNumber;
ReceiptNumber = group.CreateProperty("ReceiptNumber",out propertyExists);
' Create a shared property group.
Dim group As SharedPropertyGroup = groupManager.CreatePropertyGroup("Receipts", lockMode, releaseMode, groupExists)
' Create a shared property.
Dim ReceiptNumber As SharedProperty
ReceiptNumber = group.CreateProperty("ReceiptNumber", propertyExists)

Applies to