Aracılığıyla paylaş


IVsTextStorage2.GetVersionCookie(UInt32) Method

Definition

Gets a version cookie on the data.

public:
 int GetVersionCookie([Runtime::InteropServices::Out] System::UInt32 % pdwVersionCookie);
int GetVersionCookie([Runtime::InteropServices::Out] unsigned int & pdwVersionCookie);
public int GetVersionCookie (out uint pdwVersionCookie);
abstract member GetVersionCookie : uint32 -> int
Public Function GetVersionCookie (ByRef pdwVersionCookie As UInteger) As Integer

Parameters

pdwVersionCookie
UInt32

[out] The version cookie.

Returns

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

Remarks

The version cookie starts at 0 and is incremented every time the data in the text storage is changed.

This method should provide a quick test to determine whether the text storage contents have changed. It may produce false positives (e.g. incrementing the version number even though no substantive change was made (for example, replacing "a" with "a").

Applies to