Read-only and Write-only Properties 
Author Message
 Read-only and Write-only Properties

Does anyone out there understand the code written by the ActiveX Control
Interface Wizard to make properties read-only and write-only at design time
and run time?  It uses an Attribute statement involving VB_Memberflags and
performs an Err.Raise 387 and I can't find any documentation on any of
these.  There are numerous examples on MSDN of using VB_Memberflags, but
none of them have any explanations or comments which would help in working
out just what these things can do and how to use them.  Worse, I can't even
locate a list of Error Codes any more, either on the DVD version of MSDN or
on-line.

Can anyone point me in the right direction on this?

Bill Wood



Fri, 07 Feb 2003 03:00:00 GMT  
 Read-only and Write-only Properties
You can raise an error or...

For write only, code a Property Set/Let only. (delete the 'Get' property)
For read only, code a Property Get only. (delete the 'Set/Let' property)

If you do this, VB will generate the error.

Quote:

> Does anyone out there understand the code written by the ActiveX Control
> Interface Wizard to make properties read-only and write-only at design time
> and run time?  It uses an Attribute statement involving VB_Memberflags and
> performs an Err.Raise 387 and I can't find any documentation on any of
> these.  There are numerous examples on MSDN of using VB_Memberflags, but
> none of them have any explanations or comments which would help in working
> out just what these things can do and how to use them.  Worse, I can't even
> locate a list of Error Codes any more, either on the DVD version of MSDN or
> on-line.

> Can anyone point me in the right direction on this?

> Bill Wood



Fri, 07 Feb 2003 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Readonly and Writeonly Properties

2. Accessing a Property through read-only and read-write interfaces

3. File Properties - Summary Tab - Read and Write Properties

4. Designer tries to write to read-only VisibleColumnCount property of DataGrid

5. How: Public Read Only / Private Write Property?

6. Writing a VBS file which reads and writes to the registry

7. Qbasic: Pre-written INI read/write routines?

8. read write error when attempting to write to dbo_tblCounts (Access linked table)

9. Converting returned of a select query to read/write from read-only

10. EXCEL: Switching from READ-ONLY to READ-WRITE

11. Text box: read only/read write, how?

12. Need Folder permissions Read Only / Program Access Read Write

 

 
Powered by phpBB® Forum Software