Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8526

Re: Display Description only in COMBO BUTTON

$
0
0

I'm using it like this when I want to display description in my combobox. I'm also using SBO 9.0 PL5

 

Public cmb_Type As ComboBox

cmb_Type = frmGenerator.Items.Item("cmb_Type").Specific

oQuery = ("SELECT Code, Name FROM [" & Main.oCompany.CompanyDB & "]..[@APP_SERVICE]")

            oRec.DoQuery(oQuery)

            frmGenerator.Items.Item("cmb_Type").DisplayDesc = True

            If (cmb_Type.ValidValues.Count > 0) Then

                For i As Integer = 0 To cmb_Type.ValidValues.Count Step -1

                    cmb_Type.ValidValues.Remove(i, BoSearchKey.psk_Index)

                Next

            End If

 

 

            While Not oRec.EoF

                cmb_Type.ValidValues.Add(oRec.Fields.Item(0).Value, oRec.Fields.Item(1).Value)

                oRec.MoveNext()

            End While


Viewing all articles
Browse latest Browse all 8526

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>