Community discussion forum

C# Syntax for inserting data from gridview to an sqlserver tabe

  • 8 months ago
    I have displayed data from multiple tables to a gridview while working on an asp.net application. now I want to insert same data of a *selected row * to another table of the same database. What will be the C# syntax for that?
    Post was edited on 24/03/2009 06:38:12 Report abuse
  • 7 months ago
    Hi there are two ways to do this. one in grid view item template place asp.net controls and at that specific row id . find the control at that row that assign these controls to db object properties and than save. 2nd is place sql data source and in insert parameter set the value of grid row and construct your insert query in html design side. I hope i will help you. Regard Muhammad Idrees

Post a reply

Enter your message below

Sign in or Join us (it's free).

Want to stay in touch with what's going on? Follow us on twitter!