I am working on a class and want to set the Item property as the default property. I followed the instructions from Pearson's site, and every other site with information about it, and exported the class into a text file. I then inserted "Attribute Value.VB_UserMemId = 0" into the desired property as follows:
I then saved the file, removed the old class module from my project and imported the new. However, VB seems to be erasing the line I am trying to place into it. The default property does not work, and after exporting the class module back into the text editor I find the following (notice the line has been deleted):
What am I doing wrong?
-JTBorton
Well, You can try banging your head against the wall, but you just end up with lost-time injuries and damaged equipment. [M. Passman]
Code:
Public Property Get Item(Index As Integer) As emlAttachment
'HIDDEN CODE - DO NOT EDIT THIS SPACE
[highlight]Attribute Value.VB_UserMemId = 0[/highlight]
'END OF HIDDEN CODE
If Index > Count Then
'********** TO BE CODED **********
End If
Set Item = objAttachments(Index)
End Property
I then saved the file, removed the old class module from my project and imported the new. However, VB seems to be erasing the line I am trying to place into it. The default property does not work, and after exporting the class module back into the text editor I find the following (notice the line has been deleted):
Code:
Public Property Get Item(Index As Integer) As emlAttachment
'HIDDEN CODE - DO NOT EDIT THIS SPACE
'END OF HIDDEN CODE
If Index > Count Then
'********** TO BE CODED **********
End If
Set Item = objAttachments(Index)
End Property
What am I doing wrong?
-JTBorton
Well, You can try banging your head against the wall, but you just end up with lost-time injuries and damaged equipment. [M. Passman]