When I test my class, I met this problem, "runtime error 91: object variable or within block variable not set"
this is my test code:
Option Explicit
Dim ctest As clsexport
Private Sub Command1_Click()
With ctest
.CName = "name"
.userID = "123456"
.C_export
End With
End Sub
partly code in my class
Public m_userID As String
Public m_CrName As String
Public Property Get userID() As Variant
userID= m_userID
End Property
Public Property Let userID(ByVal vNewValue As Variant)
m_userID = vNewValue
End Property
Public Property Get CName() As Variant
CName = m_Name
End Property
Public Property Let CName(ByVal vNewValue As Variant)
m_CrName = vNewValue
End Property
I don't know how to troubleshot this error.
great appreciated any help!


When I test my class, I met this problem, "runtime error 91: object variable or within block variable not set"
Reply With Quote


Bookmarks