在VB6中,Property Set和Property Let有什么区别?

在VB6中,Property Set和Property Let有什么区别?

问题描述:

我刚刚创建了几个Property Set方法,但是它们没有编译.当我将它们更改为Property Let时,一切都很好.

I have just created several Property Set methods, and they didn't compile. When I changed them to Property Let, everything was fine.

此后,我研究了文档以查找Property SetProperty Let之间的区别,但必须承认没有一个更明智.有什么区别,如果可以的话,有人可以提供对此正确解释的指导吗?

I have since studied the documentation to find the difference between Property Set and Property Let, but must admit to being none the wiser. Is there any difference, and if so could someone offer a pointer to a proper explanation of it?

Property Set用于对象(例如,类实例)

Property Set is for objects (e.g., class instances)

Property Let用于普通"数据类型(例如,字符串,布尔值,长整数等)

Property Let is for "normal" datatypes (e.g., string, boolean, long, etc.)