473,396 Members | 1,780 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Write data to Excel file

Hi

I want to export web controls value into the Excel file.

Detail :
I have a text box where user can type the filename and on click of button a
dialog box should appear that will ask user to where to save the file and
that file should contain all the data from the webcontrols for example
<asp:label>

I tried the following code.
Response.ContentType = "application/vnd.ms-excel"
Response.AddHeader("Content-Disposition", "attachment;filename=" + fileName
+ ".xls")
Response.Write("<table><tr><td>" & Me.TotalRevenueLabel1.Text &
"</td></tr></table>")

But this code doesnt write value of the "TotalRevenueLabel1.text" inside the
Excel file but it renders whole webpage.

Please provide the solution for this as soon as possible.

Thanks

Regards,
Pauravi

Jul 21 '05 #1
0 1604

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: veens-zevenhonderdvijf | last post by:
Hi, I want to show an excel-graphs in one of my access-forms. The problem is how to refer to an embedded excel-file in my form. I can refer to an external excelfile (see below) an do some test...
0
by: Pauravi | last post by:
Hi I want to export web controls value into the Excel file. Detail : I have a text box where user can type the filename and on click of button a dialog box should appear that will ask user to...
1
by: sweety | last post by:
Hi, Very Urgent... I Need to write a structure of data which is in "C" to excel file(*.xls). So, using C/VC++ how i can create a Excel file and how i can write a data into the respective...
2
by: polabear | last post by:
I'm converting a VB6/SQL Server application to a web application. I need to read data to and from Excel and Word. I'm not allowed to install Excel and Word on the server, only on the client. Is...
4
by: Seok Bee | last post by:
Dear Experts, I have created a script to extract the Event Logs from the system into an excel sheet. The logs are separated into 2 worksheets (Application Log and System Log). After this excel...
0
by: mady1380 | last post by:
hi all i am trying to read and write data in Excel file from asp.net I am able to read the data of particular cell, but i am not able to write in Excel file. I am getting error:...
1
by: nufanvandal | last post by:
Hello, I created a web form in html, I need to create a server-side script using ASP and embed it into the html, so that when the user clicks submit, it sends(saves) the data from text boxes,...
3
by: =?Utf-8?B?YzY3NjIyOA==?= | last post by:
Hi all, I have a question for you. I have a .csv file which has many lines of data. Each line has many data fields which are delimited by ",". Now I need to extract part of data from this...
8
blazedaces
by: blazedaces | last post by:
So I have a program below which writes an excel file with multiple sheets based on inputs of sheet names, data, cell types, etc. It uses Apache POI, which is currently the only thing I found...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.