USUÁRIO:      SENHA:        SALVAR LOGIN ?    Adicione o VBWEB na sua lista de favoritos   Fale conosco 

 

  Fórum

  Visual Basic
Voltar
Autor Assunto:  CRIAR OCX DUVIDA
X-Crow Original
Pontos: 2843
VITÓRIA
ES - BRASIL
Postada em 06/05/2005 20:14 hs         
' Seção General
Private m_Caption As String
' No código
Public Property Get Caption() As String
   Caption = m_Caption
End Property
Public Property Let Caption(ByVal parValor As String)
   m_Caption = parValor
   PropertyChanged "Caption"
End Property
' O da fonte vai de brinde pra vc naum bater muita cabeça
Public Property Get Font() As Font
   Set Font = UserControl.Font
End Property
Public Property Set Font(ByVal passFont As Font)
   Set UserControl.Font = passFont
   PropertyChanged "Font"
End Property
' Coloca os eventos do userControl Lá no finzinho do code à unha(Ctrl+x e dpz Ctrl +v)
' Por último os eventos do UserControl de Carregamento e gravação de valores das
' propriedades (Essa é a melhor parteEmoções)
 
Private Sub UserControl_InitProperties()
   Set m_Font = Ambient.Font
   m_Caption = Extender.Name
End Sub
 
' Evento de Carregamento das propriedades Salvas
Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
     Set UserControl.Font = PropBag.ReadProperty("Font", Ambient.Font)
   m_Caption = PropBag.ReadProperty("Caption", Extender.Name)
End Sub
' Evento de Gravação dos novos valores das propriedades:
Private Sub UserControl_WriteProperties(PropBag As PropertyBag)
   Call PropBag.WriteProperty("Font", UserControl.Font, Ambient.Font)
   Call PropBag.WriteProperty("Caption", m_Caption, Extender.Name)
End Sub
 
Qq Coisa Tamos por ae... Abraços, Sidnei
     
Página(s): 2/2     « ANTERIOR  


Seu Nome:

Seu eMail:

ALTERAR PARA MODO HTML
Mensagem:

[:)] = 
[:P] = 
[:(] = 
[;)] = 

HTML DESLIGADO

     
 VOLTAR

  



CyberWEB Network Ltda.    © Copyright 2000-2025   -   Todos os direitos reservados.
Powered by HostingZone - A melhor hospedagem para seu site
Topo da página