Solved

Saving data from a gridview to the database

Posted on 2013-02-01
2
627 Views
Last Modified: 2013-02-02
I have a editable gridview.  The entire gridview must be editable at one time, so I am using the labels for the read only view and text boxes for the writable view.

<asp:TemplateField HeaderText="Priority 1">

 <ItemTemplate>

<asp:Label ID="lblPriority1" Visible='<%# Not (IsInEditMode) %>' runat="server" Text='<%# Eval("Priority1") %>' />

<asp:TextBox ID="txtPriority1" Visible='<%# IsInEditMode %>' runat="server" width="20px" Text='<%# Bind("Priority1") %>' />
</ItemTemplate>
</asp:TemplateField>

My need is to save the entire gridview with a single click with some kind of loop.  There are 25 rows and 12 columns.    I am not using a SQLDataSource, but am filling the grid by making a call to a stored proc in the Database layer.  

I have attached a subset of what the grid looks like.  


Does anyone have any code that could assist me.

Thanks.
cadencegrid.xlsx
0
Comment
Question by:sherbug1015
2 Comments
 
LVL 35

Accepted Solution

by:
Miguel Oz earned 500 total points
ID: 38845257
0
 

Author Closing Comment

by:sherbug1015
ID: 38846674
That helped a lot.  Thank you.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SSRS ReportViewer report timeout 7 101
C# HTTP GET method sample code 3 40
how to read json value 2 30
Message not shown 5 30
Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

911 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now