![Antiguo](http://static.forosdelweb.com/fdwtheme/images/statusicon/post_old.gif)
02/11/2009, 11:01
|
| | Fecha de Ingreso: octubre-2009
Mensajes: 29
Antigüedad: 15 años, 3 meses Puntos: 0 | |
Respuesta: Cargar una combox con dato seleccionado vb.net - win form Eduardo
La clase MyList Contiene
Public Class MyList
Private sName As String
Private iID As Integer 'You can also declare this as String.
Public Sub New()
sName = ""
iID = 0
End Sub
Public Sub New(ByVal Name As String, ByVal ID As Integer)
sName = Name
iID = ID
End Sub
Public Property Name() As String
Get
Return sName
End Get
Set(ByVal sValue As String)
sName = sValue
End Set
End Property
Public Property ItemData() As Integer
Get
Return iID
End Get
Set(ByVal iValue As Integer)
iID = iValue
End Set
End Property
Public Overrides Function ToString() As String
Return sName
End Function
End Class
Efectivamente
WgEjecutivoVtas es una variable
cuando se dispare el evento SelectedIndexChanged
se mostrara la lista ejecutivos en la combobox
y me permitira seleccionar (cambiar) un nuevo ejecutivo
almacenando el valor del codigo del ejecutivo en la variable
WgEjecutivoVtas
Gracias
Ruben |