hello!
i had problem with property in my user control! i use:
i hade this code in my User contrlo
Private WithEvents mFont As StdFont
Private Sub UserControl_Initialize()
' FONT
Set mFont = New StdFont
Set UserControl.Font = mFont
Set mTEXTBOX.Font = mFont
End Sub
Public Property Get Font() As StdFont
Set Font = mFont
End Property
Public Property Set Font(mnewFont As StdFont)
Set mFont = mnewFont
Set mTEXTBOX.Font = mFont
Set UserControl.Font = mFont
PropertyChanged "Font"
End Property
Private Sub mFont_FontChanged(ByVal PropertyName As String)
Set UserControl.Font = mFont
Set mTEXTBOX.Font = mFont
Refresh
End Sub
now, in project windows it works, i mean it change the font, when i lunch the project it comes back to original font!
any suggestion why it happens?
(i have the same the result with another proerty! i chenge it in project, it come back to default valure in exe!)
i had problem with property in my user control! i use:
i hade this code in my User contrlo
Private WithEvents mFont As StdFont
Private Sub UserControl_Initialize()
' FONT
Set mFont = New StdFont
Set UserControl.Font = mFont
Set mTEXTBOX.Font = mFont
End Sub
Public Property Get Font() As StdFont
Set Font = mFont
End Property
Public Property Set Font(mnewFont As StdFont)
Set mFont = mnewFont
Set mTEXTBOX.Font = mFont
Set UserControl.Font = mFont
PropertyChanged "Font"
End Property
Private Sub mFont_FontChanged(ByVal PropertyName As String)
Set UserControl.Font = mFont
Set mTEXTBOX.Font = mFont
Refresh
End Sub
now, in project windows it works, i mean it change the font, when i lunch the project it comes back to original font!
any suggestion why it happens?
(i have the same the result with another proerty! i chenge it in project, it come back to default valure in exe!)