Link to home
Start Free TrialLog in
Avatar of Angel02
Angel02

asked on

Populate a .net gridview with transform query results

My stored procedure returns results something like this for 52 weeks.

Category | Product | wk1Amt | Wk1Qty | Wk2Amt | Wk2Qty | ...........| Wk52Amt | Wk52Qty

I am able to populate a gridview with autogeneratecolumns ="false just like above. But I need my gridview like below with editable columns in between

Category |Product |Wk1Amt |Wk1Qty | Wk1NewQty | Wk2Amt |Wk2Qty |Wk2NewQty ..........|Wk52Amt| Wk52Qty|Wk52newQty

Another thing is I need to display only the week that I have selected.
If I am running for example only Week 1 to Week 4, the columns for Week 5 to Week 52 should be invisible as they will be blank anyways.

The columns called "Wk#NewQty" are going to have textboxes so values could be entered. Do I need to create 52*2 boundfield columns manually along with 52 template columns? Or should I dynamically add columns in GridView.
ASKER CERTIFIED SOLUTION
Avatar of Shaun Kline
Shaun Kline
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial