I want to achieve that when a user makes a selection with the combobox (cboVolgnr) 016 in my example (see pic), the results comes up and the user wants to clean up his selection but the selection is still there. I thought that the code was complete but it still doesn't works... My code:
<td style="width:50px">Volgnr</td>
<td style="width:75px"><telerik:RadComboBox ID="cboVolgnr" Runat="server" Width="75px" Filter="StartsWith"><HeaderTemplate>
<ul><li class="colvolg1">Volgnr</li><li class="colvolg2">Code</li><li class="colvolg3">EI</li><li class="colvolg4">Omschr</li></ul></HeaderTemplate>
<ItemTemplate>
<ul>
<li class="colvolg1"><%#Eval("Volgnr")%></li >
<li class="colvolg2"><%#Eval("Code")%></li >
<li class="colvolg3"><%#Eval("EI")%></li>
<li class="colvolg4"><%#Eval("Omschr")%></li >
</ul >
</ItemTemplate>
</telerik:RadComboBox>
</td >
cboVolgnr.Text = ""
Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me
.Load
Dim cn As New SqlConnection(cnnBN.ToString), cmd As SqlCommand, dr As
SqlDataReader
Dim strSQL As String = "SELECT * FROM tblBWPeriodes WHERE DJ = "
& strDJ
Try
cn.Open()
cmd = New SqlCommand(strSQL, cn)
dr = cmd.ExecuteReader
combo.DataTextField =
"volgnr"
combo.DataValueField = "volgnr"
combo.DataSource = dr
combo.DataBind()
combo.Skin =
"Office2007"
Catch ex As Exception
Throw ex
End
Try
dr = Nothing
cmd = Nothing
cn.Dispose()
cn = Nothing
cboVolgnr.HighlightTemplatedItems = True
cboVolgnr.AllowCustomText = True
cboVolgnr.EmptyMessage = "Alles"
cboVolgnr.DropDownWidth = 500
cboVolgnr.Height = 375
End
Sub
Protected Sub btnCriteria_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles
btnCriteria.Click
...
cboVolgnr.Text = ""
End
Sub
Is there something I am missing? Can you give me a help?
Kind regards,
Kris