Set Devexpress LookupEdit Datasource use msSQL Stored Procedure

Posted On // Leave a Comment
Sub __OpenRsTipe()
        Dim dtTipe As New DataTable
        With _SqlCommand
            .CommandText = "mstTipe_SELECT_id_Nama_WHERE_Merek_Honda"
            .Parameters.Clear()
            _SQLReader = .ExecuteReader
        End With
        dtTipe.Load(_SQLReader)
        With LookUpTipe
            .Properties.DataSource = dtTipe
            .Properties.ValueMember = "Nama"
            .Properties.DisplayMember = "Nama"
            .Properties.PopupWidth = 250
        End With
        _SQLReader.Close()
    End Sub

0 komentar: