How to Edit a row in the datatable

前端 未结 6 1042
说谎
说谎 2020-12-05 18:46

I have created a data table. It has 3 column Product_id, Product_name and Product_price

    Datatable tabl         


        
6条回答
  •  离开以前
    2020-12-05 18:57

    You can find that row with

    DataRow row = table.Select("Product_id=2").FirstOrDefault();
    

    and update it

    row["Product_name"] = "cde";
    

提交回复
热议问题