FormView in Edit mode

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Rosa Matias

    FormView in Edit mode

    I'm using a FormView but I can not put it in edit mode. The formview is connected to a sqldatasource whose query receives a parameter from other form (using a querystring).
    Can someone help me?
    Thanks in advance.
    Rosa Matias
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    When developing applications in .NET, and you have a problem understanding how to use a control, the best resource to refer to is the MSDN Library. This library contains documentation on all of the .NET controls and even articles on best-practices and patterns that comes in handy.

    Check out the article on the FormView control for information on how to use it.

    -Frinny

    Comment

    • aallen
      New Member
      • Jan 2013
      • 1

      #3
      No one ever put a solution to this. I've read the article referred to in the response and it never mentions "How" to set the EditMode it merely mentions it can be set. In what code block is it placed?

      I would like to do what this person is asking about and I believe I would need to pass the mode as a parameter? and then perhaps set the mode using code behind? but I can't seem to make it work.

      Comment

      • Frinavale
        Recognized Expert Expert
        • Oct 2006
        • 9749

        #4
        Use the FormView's ChangeMode method to switch the FormView control to the specified data-entry mode.

        For example:
        Code:
        myFormView.ChangeMode(FormViewMode.Edit)
        -Frinny

        Comment

        Working...