Cita:
Iniciado por piojoman Hola:
Alguien sabe donde puedo conseguir informacion (en lo posible en español) para crear mis propios OCX... Y tambien me interesaria crear DLL para VB6.
Muchas Gracias!!!
Bueeeee, crear un OCX no tiene tanto misterio, es solo abrir el vb6, y nuevo control ActiveX...
y para poner propiedades usamos
Código:
Private p_una_propiedad As Integer
Public Property Let Una_Propiedad(ByVal New_Propiedad As Integer)
p_una_propiedad = New_Propiedad
PropertyChanged "Una_Propiedad"
'Aquí podéis poner una acción que queréis que se realize al cambiar la propiedad.
End Property
Public Property Get Una_Propiedad() As Integer
Una_Propiedad = p_una_propiedad
End Property
Private Sub UserControl_ReadProperties(PropBag As PropertyBag)
Una_Propiedad = Propbag.ReadProperty("Una_Propiedad",0)
End Sub
Private Sub UserControl_WriteProperties(PropBag As PropertyBag)
Call Propbag.WriteProperty("Una_Propiedad",p_una_propiedad,0)
End Sub
Y para los Eventos pones en las (Declaraciones):
Y cuando quieres que se produzca el evento: