PRB: Datatype Error Accessing Property With _Access Method (194202)
The information in this article applies to:
- Microsoft Visual FoxPro for Windows 6.0
This article was previously published under Q194202 SYMPTOMS
Returning an invalid datatype in the _Access method of an object's property
results in the following error when you reference that property:
Datatype is invalid for this property.
RESOLUTION
To avoid this error, make sure that the datatype returned is valid for the
property being accessed.
It is recommended that the return value of the _Access method be the
property's value.
Example:
PROCEDURE object1.INTERVAL_Access
RETURN THIS.INTERVAL
ENDPROC
In the rare instance where you need to return a value other than the
property's value, changing the value of the property, and returning the
property ensures that you are storing the value for future comparison.
NOTE: You should consider changing the value of a property in the
property's _Access method an extreme case, and make sure you fully document
the change.
STATUS
This behavior is by design.
Modification Type: | Major | Last Reviewed: | 12/11/1999 |
---|
Keywords: | kbprb KB194202 |
---|
|