Hi, I want to create a GridView with client side updatable amount column. Here is the table structure
that I need to pull from the database. Offcource, I need to calculate the subtotal and the grandtotal
from the client side so whenever the user change any value ( textbox of the amount column ) the changes
should reflect on the subtotal and the grandtotals..... appreciate anyone input.
thanks
bob
-------------------------------------------------
Id Group Program Subprog|Amount
1 AAAA Prog1 Sub1 100
2 AAAA Prog2 Sub2 200
3 AAAA Prog3 Sub3 300
Subtotal 600
4 BBBB Prog1 Sub1 400
5 BBBB Prog2 Sub2 500
6 BBBB Prog3 Sub3 600
7 BBBB Prog4 Sub4 700
Subtotal 1800
8 CCCC Prog1 Sub1 800
9 CCCC Prog2 Sub2 900
10 CCCC Prog3 Sub3 1000
11 CCCC Prog4 Sub4 1100
Subtotal 3000
Grandtotal 5400
How to create a gridview that has client side updatable column. So, when a user change the value in any textbox of the amount column, the subtotal is automatically updatable and the Grand Total too
bobwhite
Member
704 Points
669 Posts
Gridview & client side subtotal and grandtotal calculations
Nov 19, 2012 09:12 PM|LINK
Hi, I want to create a GridView with client side updatable amount column. Here is the table structure that I need to pull from the database. Offcource, I need to calculate the subtotal and the grandtotal from the client side so whenever the user change any value ( textbox of the amount column ) the changes should reflect on the subtotal and the grandtotals..... appreciate anyone input. thanks bob ------------------------------------------------- Id Group Program Subprog|Amount 1 AAAA Prog1 Sub1 100 2 AAAA Prog2 Sub2 200 3 AAAA Prog3 Sub3 300 Subtotal 600 4 BBBB Prog1 Sub1 400 5 BBBB Prog2 Sub2 500 6 BBBB Prog3 Sub3 600 7 BBBB Prog4 Sub4 700 Subtotal 1800 8 CCCC Prog1 Sub1 800 9 CCCC Prog2 Sub2 900 10 CCCC Prog3 Sub3 1000 11 CCCC Prog4 Sub4 1100 Subtotal 3000 Grandtotal 5400 How to create a gridview that has client side updatable column. So, when a user change the value in any textbox of the amount column, the subtotal is automatically updatable and the Grand Total tooCatherine Sh...
All-Star
23382 Points
2490 Posts
Microsoft
Re: Gridview & client side subtotal and grandtotal calculations
Nov 23, 2012 06:11 AM|LINK
Hi,
If you want to design Gridview to show subtotal and grandtotal, you can follow the link below which shows how to do it:
http://www.dotnettwitter.com/2011/02/group-total-grand-total-in-grid-view.html
And the similar thread below:
http://aspguy.wordpress.com/2008/06/17/a-gridview-control-with-subtotals/
Best wishes,
Feedback to us
Develop and promote your apps in Windows Store