Click here to Skip to main content
13,351,239 members (50,626 online)


QuestionFiltering in header Pin
byka19-Sep-12 2:40
memberbyka19-Sep-12 2:40 
AnswerRe: Filtering in header Pin
Sandeep Mewara19-Sep-12 10:30
mvpSandeep Mewara19-Sep-12 10:30 
Based on the code, it looks like a dropdownlist does exists from before. In the RowDataBound event you are trying to populate data in that pre-existing dropdown. Since, it pre-exists, you can define a selected change index for it.

In case you want to define it at runtime in RowDataBound, then you need to add this:
AddHandler ddlFilter.SelectedIndexChanged, AddressOf Me.ddl2_SelectedIndexChanged
ddlFilter.AutoPostBack = true

Private Sub ddlFilter_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs)
        'your code 
End Sub

Sandeep Mewara
Microsoft ASP.NET MVP

[My latest Article]: Server side Delimiters in ASP.NET[^]

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Advertise | Privacy |
Web01 | 2.8.180111.1 | Last Updated 19 Jan 2018
Copyright © CodeProject, 1999-2018
All Rights Reserved. Terms of Service
Layout: fixed | fluid