RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TPropertyEditor.GetEditValue Method (WideString)

Retrieves a string to represent the property's value, or, if the value is not available, an error message.

Pascal
function GetEditValue(out Value: string): Boolean; overload;
function GetEditValue(out Value: WideString): Boolean; overload;
C++
__fastcall Boolean GetEditValue(AnsiString Value);
__fastcall Boolean GetEditValue(BSTR Value);

The Object Inspector calls GetEditValue (through the IProperty interface) to obtain the string it displays as the property value. 

GetValue formats the string displayed in the Object Inspector to represent the property value and returns it as the Value parameter. Unlike the GetValue method, which is the read access method for the Value property, GetEditValue does not raise an exception when the property value is unavailable. Instead, it assigns an error message to Value and returns false.  

GetValue returns true if Value returns a string representation of the property value.

Note: GetEditValue is not a virtual method. To provide a method that supplies the string that appears in the Object Inspector, override the GetValue method instead. GetEditValue calls GetValue to fetch this string.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!