PDA

View Full Version : Coding to load Excel Table


Death Dream
02-22-2008, 02:44 PM
Alright guy's if you remember I designed the Adesa website awhile back and now I am transfering it to a better webhosting company than the one they currently have.

First let me explain on what I am doing.
I got an .asp file that goes and loads a .csv file (Excel Table)


Dim fso, f1, ts, sLine
Set fso = CreateObject("Scripting.FileSystemObject")
set f = fso.GetFile("d:\adesadesmoines.com\lists\RUNLIST.csv")
Set ts = f.OpenAsTextStream(1)
Dim iXSo if we go to http://adesadesmoines.com/ and click on Runlist, everything loads up great.

Now ... onto the problem.
My hosting company I am moving to is here: http://74.52.59.18/~djadesa/ (http://74.52.59.18/%7Edjadesa/)
Click on runlist ...
I guess this is Sun ONE asp and they do not support that on any of their servers.

Is there any other kind of code I can use to load these .csv files? I can convert the .csv's to excel files as well if I really need to but I rather not do that.

Thanks,
Death Dream

domedia
02-22-2008, 03:00 PM
Since you're getting a new host, why not move to a host that fulfills your criteria? Just a thought.. :)

davidj
02-22-2008, 03:09 PM
what dont they support on thier servers?

also your transfering to a better hosting company....

this is worse if your app dont work and its the host at fault

it cant be the csv process that they are stopping. It must be a coding issue

Death Dream
02-22-2008, 03:19 PM
Since you're getting a new host, why not move to a host that fulfills your criteria? Just a thought.. :)

Well my current host for this company is charging me $30 for 500mbs of bandwidth .. anything is better than them.

Error Type:
Sun ONE ASP VBScript runtime (0x800A0035)
File not found
/~djadesa/list pages/Runlist.asp, line 7 On line 7 is:
set f = fso.GetFile("d:\adesadesmoines.com\lists\RUNLIST.csv")I could be getting that error because it is pulling from adesadesmoines and not this hoster at http://74.52.59.18/~djadesa/ (http://74.52.59.18/%7Edjadesa/)

Just is there a way I can change my code to work with them? I never liked .asp anyways it was just easier for me to work with when redesigning the site.

Edit: They support Chilisoft ASP but not Sun ONE ASP

~Death Dream~

domedia
02-22-2008, 03:30 PM
Well my current host for this company is charging me $30 for 500mbs of bandwidth .. anything is better than them. Not sure I agree.. $30/m for something that works for you or $15/m for something that does not work..

Death Dream
02-22-2008, 03:38 PM
Not sure I agree.. $30/m for something that works for you or $15/m for something that does not work..

Aaaaaaaaaargh can you just help me figure out a new coding way to do this. I need more bandwidth for my site because I am going way over the limit and was told about this. Just help me code this differently, that is all I am asking. I already know it doesn't work and the other site does work, that is why I am here. I didn't ask for you to tell me what I already know, I asked for help on coding this differently.

Now, please, can we drop the whole hosting thing and get back on topic with a solution to the coding situation. I want this to work with these guys.

Thanks,
Death Dream

davidj
02-22-2008, 03:45 PM
errr...

it doesnt work!

just thought id mention it!

davidj
02-22-2008, 03:46 PM
seems to me it cant find your csv

Death Dream
02-22-2008, 04:13 PM
seems to me it cant find your csv

Yeah, I think that is because it is trying to load it from the old hoster that is currently working.

set f = fso.GetFile("d:\74.52.59.18\~djadesa\lists\RUNLIST.csv")Say I do change it so it loads from the IP address instead. I don't think this will work because they use Chilli and I use Sun ONE.

I will upload this and see what happens.

Edit: lol that didn't work XD.

Is there another way to get excel tables to load in HTML format, that is all I am going for.

~Death Dream~

davidj
02-22-2008, 04:17 PM
you have an absolute path in your GetFile

its pointing to d:

if your file is on another host you need get it through http

http://domain.com/path/path/file.csv

Death Dream
02-22-2008, 04:49 PM
Just tired http://74.52.59.18/~djadesa/public_html/list%20pages/Runlist.asp

Got a 404 error lol.

~Death Dream~

davidj
02-22-2008, 04:50 PM
have you not got a domain for that machine

use that

Death Dream
02-22-2008, 04:52 PM
It domain is adesadesmoines.com as well, but wont the DNS try to route it back to my old hoster?

Edit: oops, posted the wrong link above, sorry.
I meant to put: 74.52.59.18/~djadesa/public_html/lists/runlist.CSV

It's on a Linux machine so we changed the /'s the other way.

~Death Dream~

Cary
02-23-2008, 12:55 AM
In the fourth post of this thread (http://www.dreamweaverclub.com/forum/showthread.php?t=27168) I suggested a technique which may work for you.

davidj
02-23-2008, 11:21 AM
i thought you had a seperate domain for both spaces

Death Dream
02-25-2008, 08:16 PM
The guys at the hosting company are great. They looked at the code them selves and fixed it to work the way I wanted =D

Their Help Desk is great.

Anyways, they changed the Line 7 code to look like the following:

set f = fso.GetFile("/home/djadesa/public_html/lists/runlist.CSV")

~Death Dream~

davidj
02-25-2008, 08:30 PM
so your saying that both sites are on the same machine?

i dont understand how that line of code can access a different machine

Death Dream
02-25-2008, 09:38 PM
so your saying that both sites are on the same machine?

i dont understand how that line of code can access a different machine

No I never said that. They are both different webhosting companies.

The DNS just points to the server, and I have two servers right now doing the same thing. The DNS is currently pointed to my old hoster. 74.52.59.18 is my new hoster. I have yet to point the DNS to the new hoster yet. Both servers are just waiting for a reply from the DNS. After I get the DNS changed to the new hoster I will cancel my account with my old hoster.

My old hoster used a Windows based server, my new hoster uses Linux, thus why my code didn't work the way it would on a windows machine.

Hope that cleared it up.

~Death Dream~