| Home | Register | FAQ | Members List | Search | Today's Posts | Mark Forums Read |
|
|
#1 (permalink) |
|
Registered User
Join Date: Jan 2006
Posts: 4
|
Trying to create a file on client-side!
Hi There, I am using vbscript. I needed to create a file on the client-side from server-side, but I realized it is not possible. One way might be using ActiveX, but I have no idea where to begin with. Can anyone help me get started on it or have a better suggestion on approaching this problem? Thanks very much, Armon |
|
|
|
|
|
#4 (permalink) |
|
vague™
Join Date: Mar 2004
Location: Glasgow
Posts: 5,513
|
For a start you haven't told us what kind of file you wish to generate, nor any other useful information. I'm/We're not here to do other people's jobs. At least make an effort to look like you've done some research on the subject before asking for help. |
|
|
|
#5 (permalink) |
|
Registered User
Join Date: Jan 2006
Posts: 4
|
I'm sorry if I did not provide you with enough information. Using vbscript, I need to create a simple text file on the sever-side and have it downloded to the local machine of the client. Now, I did create my text file with: Set FS = Server.CreateObject("Scripting.FileSystemObject") Set myFile = FS.CreateTextFile("C:\testfile.txt", True) But, the part I need a hint on is how to download it to the client side. By the way, this is within a local network, if helps. Thanks |
|
|
|
#8 (permalink) |
|
Rough Creep Arse™
|
Can you not create the file you need the user to download and then offer it as a link? Otherwise, like mike suggested content-type - which will rewrite the http headers and prompt the user to download. Note you can't force the user to download a file (except perhaps with the epitome of security "activex"). |
|
|
|
#10 (permalink) |
|
mingin dawg baitch
|
Response.Redirect("testfile.txt") or.... Code:
|
|
![]() |