By now, your code should look like this:
Dim TextVariable As
String
Event Click()
Event
KeyPress(KeyAscii As Integer)
Private Sub Command1_Click()
MsgBox (TextVariable)
RaiseEvent
Click
End Sub
Private Sub Command1_KeyPress(KeyAscii As Integer)
RaiseEvent KeyPress(KeyAscii)
End
Sub
Private Sub
UserControl_Resize()
Command1.Width =
UserControl.Width
Command1.Height =
UserControl.Height
End Sub
Public Property Get Text() As
String
Text = TextVariable
End Property
Public Property Let Text(ByVal
New_Text As String)
TextVariable = New_Text
PropertyChanged "Text"
End Property
Private Sub UserControl_ReadProperties(PropBag
As PropertyBag)
TextVariable =
PropBag.ReadProperty("Text", "There is no message")
End
Sub
Private Sub UserControl_WriteProperties(PropBag As PropertyBag)
Call PropBag.WriteProperty("Text", TextVariable, "There is
no message)
End Sub