bert_vbulletin3_import38243
New Member
I have a gridview which I binded to an objectdatasource. I added 3 dropdownlist in the edittemplate field called ddlHours, ddlMin, ddlPeriod. I have 2 thing that I am trying to do here. First I have a datetime field in SQL that stores StartDate and StartTime. I am breaking it up like so \[code\]cast(grp.StartDateTime as date) as StartDateconvert(varchar,cast(grp.StartDateTime as time) as StartTime\[/code\]So the gridview ItemTemplate is pulling the correct values in both textboxes. The problem is when I am going to edit I want to Take my StartTime value on Gridviewediting and split it into ddlHours, ddlMin, ddlPeriod(Am or PM). Then bind those dropdownlist in the Gridview's editing event.