Creating An Excel File From A Db
I do not get an error, but I also do not get any data in the excel file. I
know it is connecting to the db Code:
I do not get an error, but I also do not get any data in the excel file. I
know it is connecting to the db Code:
From ASP I create response, which is to be shown as an Excel worksheet in the user's browser (by setting the ContentType and creating a table). This works fine.
Does anybody know what to do, if one of the cells should contain a multiline text? I already tried by inserting a <br> inside the <td>. But this won't work.
I want to update Excel file when i update database.
View Replies View Relatedi want to generate excel spreadsheet from asp by fetching record from access database. i want to save the excel file on the server and make the excel file read-only too. can i do this in anyway ? if yes, then plz help me by providing with samples or tutorials.
View Replies View RelatedI got the following error even the document itself and its parent/children folders are writeable. The IURS_machinename has all the Administrator permissions (NOT Guest group). The "test1.xls" document is editable through Excel.
Error Type:
Microsoft Excel (0x800A03EC)
Cannot access read-only document 'test1.xls'.
/CreateExcel.asp, line 222
The following is the code .......
var ExApp = new ActiveXObject("Excel.Application"); // This is line 222
if (ExApp != null) {
ExApp.Visible = false;
ExApp.Application.Workbooks.Open("c: est est1.xls");
i'm trying to display a page in an excel format.
I'm using:
Response.ContentType = "application/vnd.ms-excel"
at the beginning
it opens an excel web sheet, but all i get is:
Code:
I am creating a website in which users will be able to query an sql database by several different criteria (i.e.- name, department,supplier, part#, date). What will return to the user will be a webpage with the column headings that they selected in their search criteria (i.e.- name, supplier, part#) and below those column headings, a list of the results.
I want the user to be able to print this report or export it to an excel file, this is the part that is tripping me up.Any ideas about this? Am I going about it all wrong?
I have an ASP page that create an Excel object.
xlsApp = new ActiveXObject("Excel.Application");
It works fine when using under Administrator logon name but not under other users. Proper permissions have been given to IUSR_servername for all folders.what I am missing.
I am tryign to create an excel spreadsheet/chart using office web components in asp. However I seem to have a registeration problem. I'm running office2003 and IIs is also running on my pc. When the following line exceutes an error "invalid string class is thrown" :
set objChartSpace = Server.CreateObject("OWC.Chart")
I have intalled owc again but still no luck. IS it a registeration problem ?
We have an application where the user fills out many screens and when
they are done, we are supposed to display the text they entered in a
word or excel format. That is fairly easily accomplished by changing
the content type in the response object.
On one of the screens where they enter data, they also have the
ability to upload a word document containing additional information.
This is also not a problem, and is working fine.
Now they have decided that when we create the document with all of the
text fields in it, they want to embed the word document that they
uploaded. Is this possible? I have been trying to find a way to do
this and so far haven't come up with anything.
I want 2 create a survey Web Form that people can fill in. I then want the data entered to be saved to an Excel spreadsheet located on a server.
Can .ASP handle this kind of task? and if so does anyone know the code required to perform this function?
The data entered will be RAW and the .ASP (or whatever required programming) will need 2 process and convert the data into the spreadsheet.
Also, would it be possible to run this from a stand alone machine so that the web form, .ASP and spreadsheet are all contained on the machine and have no outside influences?
It works if the file in on the server side, how to use the component (DSOleFile) with the file on the client side? Also how can I calculate the width of the file. (Page set up - Landscape or porrait). Code:
View Replies View RelatedI know how to use ASP to create and write into a .CSV file on the server, but I have a small problem. Every time I write to the file I am adding new lines each time. I don't know how to wipe the previous contents out, and I thought this is probably a no-brainer for you guys ...
So, I'm looking either to delete the file at the start of the process and start from scratch or
* open the file
* wipe all contents from file
* write to the newly cleaned file
How can i create a ZIP file from a folder (full of files) of the server.?
View Replies View RelatedCan i create a pdf file with asp by using my database information..?
View Replies View RelatedAll I want is a txt file I can write to... and I have a hard time doing it. Only a text file, which I can write strings too (incl timing). My ASP books do not have anything on it and some examples here dont work either.
View Replies View RelatedIs there any way to create a tif file from ASP? I would like to essentially create a tif of a formatted textual document.
View Replies View RelatedIm trying to create an XML file dynamically with asp and a data base. everything is working well until the bit where i need to write the file to my server.
I have been using this:
Code:
Set WriteStuff = rsPhotos.OpenXMLFile(strSiteLocationURL & "P4M_new_images.xml", 2, True)
But I now realize that my xml feed is not a .txt file, so I changed it OpenTextFile to OpenXMLFile but it does not work?
i want to generate invoice or bill of an order from an asp application and i want that in xls format and cannot be edited. is there any way to do it......? if yes plz let me know how or the source or tutorials for the same. In short i want to generate invoice in a manner in which user can't edit his invoice which he receives in his email........and i want to do this free......not buying any component.
View Replies View RelatedI have been able to create and Active Server Page that when I link to
it will ask if I want to download to an excel file which I do want. It
works well, but there is one thing that I haven't been able to get to
work yet.
The ASP page has a logo picture in it and I want the picture to
download into the excel file also. It doesn't. My code is the
following:
Response.ContentType = "application/vnd.ms-excel"
Response.Buffer = true
Response.Clear
Response.AddHeader "Content-Disposition",
"attachment;filename=svra_excel.xls"
<!--#INCLUDE FILE="svra_report.asp"-->
the svra_report.asp is another page with the excel info in it.
Does anyone know how I can get the logo to download also?
I have manage to create a word doc from lotus notes using the createobject("Word.Application"). Now I wanted to add some text in a field on the template. I want to know how to insert a newline in the field.Also I have created a table in the doc file, now i wanted to know how to place at a desired position in the file.
View Replies View RelatedWhen an introducer is logged onto our site, I want to create a separate directory for them and place in this an index.asp page that will redirect including a variable to identify them.
I have created the folder with no problem, but when I try and create the ASP file, I'm getting errors. Code:
I need to extract some blobs (chm files, actually) from a database and save their contents on the server (recreate chm files).
I tried to do it in several ways (writing the contents to a stream and save the stream to file, writing the contents directly to file, I couldn't figure out how to do it by using the class ADODB.File) but none of them worked.
i have some difficulty in creating text file, my question is that how can i create a text file on any website through ASP,
View Replies View RelatedI've created an ASP search engine for a site I'm working on. Does anybody know a good script that will create a log file with all the search requests in.
I'm happy reading / writing data from a database with ASP, I'm afraid I come unstuck when I have to start writing data to loose files on the server. Any help or a link to a good tutorial would be gratefully received.
send me the code for creating text file on client side through asp. or is there any way to direct copy a file from server to client without asking to downloading the file?
View Replies View RelatedI want to Convert Excel Files to CSV files using ASP code CanAny body help me out in this.
View Replies View RelatedI have a page that creates a .CSV file that has been migrated over to
Windows Server 2003 from Windows 2000 Server. It worked fine before I
moved it, but now when it creates the .CSV file, and you open it, the
first row opens in cell A1 and the second row opens in cell A2. Code:
The title looks a bit odd, but it is what I really need
I have different users, which I get the information from them in an ASP page, the data is stored in a SQL database, one of these users is authorized to check and close the data entry.
Once the data entry is closed, an ‘Excel’ file should be generated according the entered data and be placed in a directory for use of other users.
My problem is how I can generate the mentioned ‘Excel’ file by clicking a button in an ASP page and transfer the recorded data in it.
I have to add a feature, on click of button file open as dialog box will open and user can attach a excel file. Then we can able to validate, actually file attached or not, it is excel file or not etc.. if everything is ok app will will do further processing on the file.. Can anybody suggest me the easy way out without licencing issues.. Since vbscript and jscript is used any fee tool available...I tried to do it through MSComDlg.CommonDialog but it is a licenced version. Also I tried to do it through <input type=file>
but here one text box and browse button gets added..
I am trying to create an excel file consisting of data from a SQL database using asp. I dont want the file to open up in the browser. I want the file to be opened in Microsoft excel. I have seen similar questions out here but no answers.
View Replies View RelatedOne of the pages of my application opens an Excel 2000 workbook in a
new window using Javascript. The workbook is read only and I use a
window.open command to open the workbook. On the workbook's
BeforeClose event I have a code to avoid the 'Save' dialog: Me.Saved =
True
If I open the page locally, change some content and close the
workbook, the 'Save' dialog does not appear, as expected. As soon as I
open the workbook on the web, the 'Save' dialog still appears when I
close the window. I need to allow my users to change the contents of
the workbook but they cannot save the workbook. Is my approach wrong?
How can I avoid the 'Save' dialog?
Can anyone help with this? Here is the code I am using. The problem
is, where it checks if a file exists, it always goes to else. Even if
the file is there, it won't open the file, goes straight to else part
of statement.
<%
If Session("strLogID") = "" Then
Response.Redirect("http://website/pages/login.asp")
Else
strfile = Request.Form("month") & Request.Form("day") & " Misses" &
".xls"
Set fs = Server.CreateObject("Scripting.FileSystemObject")
If fs.FileExists("http://website/webreports/Misses/" & strfile) THEN
Response.Redirect("http://website/webreports/Misses/" & strfile)
Else
Response.Redirect("http://website/pages/missedreport.asp")
End If
End If
%>