Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
462
Binding FormView with WebDateTimeEdit
posted

How do you use the WebDateTimeEdit control with the standard FormView control?

Here's an abbreviated version which will not update correctly as the time shown is always the current time... not the DB time.

<asp:FormView
        ID="FormView1" runat="server" DataKeyNames="ID"
        DataSourceID="UserDataSource" DataMember="DefaultView">

<%-- removed code for clarity --%>


  <EditItemTemplate>
           <igtxt:WebDateTimeEdit ID="WebDateTimeEdit1" runat="server"
                Value='<%# Bind("QuietStart") %>' EditModeFormat="t" DisplayModeFormat="t">
            </igtxt:WebDateTimeEdit>

           <asp:TextBox ID="PagerTextBox" runat="server" Text='<%# Bind("Pager") %>' />
  </EditItemTemplate>

 

<%-- removed code for clarity --%>

Parents
No Data
Reply
  • 462
    Verified Answer
    Offline posted

    I figured it out.... Make sure you bind to Value instead of Text and make sure your datasouce is up to date. My SQLdatasource was missing some columns thus they never were gettting updated.

Children
No Data