共用方式為


SharedProperty.Value 屬性

定義

取得或設定共用屬性的值。

public:
 property System::Object ^ Value { System::Object ^ get(); void set(System::Object ^ value); };
public object Value { get; set; }
member this.Value : obj with get, set
Public Property Value As Object

屬性值

共用屬性的值。

範例

下列程式代碼範例示範如何使用 Value 屬性來擷取儲存在共用屬性中的值。

// Retrieve the value from shared property, and increment the shared 
// property value.
nextReceiptNumber =  safe_cast<int>(ReceiptNumber->Value);
ReceiptNumber->Value = nextReceiptNumber + 1;
// Retrieve the value from shared property, and increment the shared
// property value.
nextReceiptNumber = (int) ReceiptNumber.Value;
ReceiptNumber.Value = nextReceiptNumber + 1;
' Retrieve the value from shared property, and increment the shared 
' property value.
nextReceiptNumber = Fix(ReceiptNumber.Value)
ReceiptNumber.Value = nextReceiptNumber + 1

適用於