Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. datagrid

datagrid

Scheduled Pinned Locked Moved ASP.NET
databasetutorialquestionannouncement
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    mak_chill
    wrote on last edited by
    #1

    i want to know that after connecting the database with datagrid , how to update and cancel records by using edit button of datagrid? manoj kumar

    T J 2 Replies Last reply
    0
    • M mak_chill

      i want to know that after connecting the database with datagrid , how to update and cancel records by using edit button of datagrid? manoj kumar

      T Offline
      T Offline
      tojamismis
      wrote on last edited by
      #2

      make a datagrid EditItem method from the Properties window of the datagrid. (Use the lightning bolt icon at the top to get to the methods.) In this method do this (Don't quote me on the signature, I don't know it off the top of my head.) private void dg_EditCommand(object source, DataGridCommandEventArgs e) { dg.EditItemIndex = e.Item.ItemIndex; dg.DataBind(); } And then for your cancel use. private void dg_CancelCommand(object source, DataGridCommandEventArgs e) { dg.EditItemIndex = -1; dg.DataBind(); } Torin Blair
      'In the immortal words of Socrates - "I drank what?".'

      1 Reply Last reply
      0
      • M mak_chill

        i want to know that after connecting the database with datagrid , how to update and cancel records by using edit button of datagrid? manoj kumar

        J Offline
        J Offline
        Jesse Squire
        wrote on last edited by
        #3

        DataGrid Girl[^] has a huge repository of data grid articles. I'd recommend that you visit for all of your data grid related needs. In the meantime, this[^] article gives a good overview of editing data within a data grid. Hope that helps. :) --Jesse

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups