472,125 Members | 1,390 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,125 software developers and data experts.

input data in asp.net and analysis with pivot table

I have created a asp.net form for user to input data. After input the data,
user need to click a button to export the input data to excel for data
analysis with excel pivot table function. is it possible to do that?? if so,
any sample for me as i am a new in designing pivot table with asp.net
million thanks
Nov 18 '05 #1
1 3025
Grey,
I don't know the architechture of your aspx project. One of the way you can achieve this by using an excel template file with -a dynamic data source, a pivot table and a pivot chart(if you need it as well). I did this by using a 3rd party excel writer tool called aspose.excel because I can run multiple instances without any problem. You should be able to use Excel Interop to accomplish this.

The idea, in simple term, is-- overwrite the data source worksheet and set the option for the pivote table to refresh on data change. When you open the excel file, the pivot table is populated with new information.

Hope this help.
Prodip

How to create a dynamic data source?
Use a Dynamic Data Source

You can use a dynamic formula to define the source range for a Pivot Table. As new items are added to the table, the named range will automatically expand.

1. Name the Range

1.. Choose Insert>Name>Define
2.. Type a name for the range, e.g. Database
3.. In the Refers To box, enter an Offset formula that defines the range size, based on the number of items in a column that doesn't contain any blank cells. , e.g.:
=OFFSET(Data!$A$1,0,0,COUNTA(Data!$A:$A),7)
In this example, the list is on a sheet named 'Data', starting in cell A1. The arguments used in this Offset function are:
1.. Reference cell: Data!$A$1
2.. Rows to offset: 0
3.. Columns to offset: 0
4.. Number of Rows: COUNTA(Data!$A:$A)
5.. Number of Columns: 7
Note: for a dynamic number of columns,
replace the 7 with: COUNTA(Data!$1:$1)
4.. Click OK


"Grey" <er*******@i-cable.com> wrote in message news:%2***************@TK2MSFTNGP10.phx.gbl...
I have created a asp.net form for user to input data. After input the data,
user need to click a button to export the input data to excel for data
analysis with excel pivot table function. is it possible to do that?? if so,
any sample for me as i am a new in designing pivot table with asp.net


million thanks

Nov 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by ben moretti | last post: by
2 posts views Thread by Rob | last post: by
1 post views Thread by Grey | last post: by
7 posts views Thread by Dave | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.