Solved

Saving data from a gridview to the database

Posted on 2013-02-01
2
659 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 36

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

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

730 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