473,508 Members | 2,437 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

open excell file with asp

2 New Member
hello sir,
i need to know the code in asp,which fetches data from excel files and transfers it to access database or postgresql,as per the requirements of the user?
Jan 23 '07 #1
1 1214
jhardman
3,406 Recognized Expert Specialist
if the excel file is set up right, you can connect to it as if it was a database:

Expand|Select|Wrap|Line Numbers
  1. dim connect, query, book, file
  2. file = "/book1.xls"
  3. set connect = server.createobject("ADODB.connection")
  4. connect.open "Provider = Microsoft.Jet.OLEDB.4.0;Data Source="&_
  5.    server.mapPath(File)&"; Extended Properties=Excel 8.0;"
  6. set book = server.createobject("adodb.recordset")
  7.  
then you can access the data as if it was a db, and deposit it in a second database using a separate db connection.

Please let me know if this was helpful.
Feb 7 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
1364
by: Robert Halstead | last post by:
Hi guys, I have a asp.net web app and it's connecting to an excell 2003 document (in another folder) via OleDataAdapter. Everything works and all, it's just that when I shutdown IE and try to...
0
795
by: Sam | last post by:
Hi All, I would like to know if it is possible to group three excell files with only one worksheet inside each file into one excel file with three worksheets so, at the begining I have 1...
4
3709
by: Leeor Chernov | last post by:
Hi , I Used the object Excell Application(COM INTEROP) and it is staying as an open process, And the owner(User Name) is ASPNET Altough I try to release it with :...
2
2028
seshu
by: seshu | last post by:
hi every body This is seshu i have doubt in mysql i have some date in excell sheet to export that data i have copied all the data into a text file and the wrote this code in...
1
2111
by: yduani | last post by:
Hi, I'm running 2 different executables: One saving infinitely an excell file, Other Read it infinitely. time duration for Save/Open is randomally. This 2 applications works fine differently,...
2
1622
by: Twanne | last post by:
Hi, I've got these files in excell that need to be imported to access. Now I've got one file, and when I try to import it, it acts weird. There are two fields in the excell fiile (Start, Stop)...
1
2270
by: thripurari | last post by:
Hi ! Dear all! I am getting a problem while binding the data source to the ultragrid . pls can any one could help me to bind the excell file to my ultra grid. My Question is: How to bind the...
1
1444
Ali Rizwan
by: Ali Rizwan | last post by:
Hi all, I m creating a database. The data for database will fetched from an excell sheet. Now how can i read an excell sheet and update my database with that excell sheet. Or I want to show...
0
1353
by: chandan | last post by:
Hi, I have written an application for exporting grid data to excel using asp.net and c#.After writting the data in excel I save it in a folder inside my application.After that I invoke the file...
0
970
by: up2you | last post by:
Hi, Below there is a example code that i saved from web page source. in this site when i click "Excell'e Aktar" the excel file download page appears. What i want to do is; i want to open this...
0
7223
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7114
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
7321
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
5623
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,...
0
3191
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3179
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1544
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
762
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
412
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.