473,586 Members | 2,707 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SA-FileUp Secure Download Issue - Please HELP!

Hi Everyone,

I was wondering if anyone has ever successfully used SA-FileUp's download
feature. I am being forced to change from
"ASPSmartUpload " as the server I am moving everything to is using SAFileUp
version 3.2.
I ran through their documentation and found a section called "secure
download", unfortunately, their examples do not work
at all!
On Netscape 7, the file "pretends" to download (after changing the file
extension), but only an empty file is created.
On IE 6, I simply get an Internal Server Error (when calling the
TransferFile method of my object).

Here is the code (verbatim from the documentation):

Set oFileUp = Server.CreateOb ject("SoftArtis ans.FileUp")
Response.Conten tType = "applicatio n/x-msdownload"
Response.AddHea der "Content-Disposition", "attachment;Fil eName=""" &
FileName & """"
oFileUp.Transfe rFile FilePath

I also tried:

Set oFileUp = Server.CreateOb ject("SoftArtis ans.FileUp")
Response.Conten tType = "applicatio n/x-msdownload"
Response.AddHea der "Content-Disposition", "attachment;Fil eName=""" &
FileName & """"
Set oFM = Server.CreateOb ject("SoftArtis ans.FileManager ")
Set oFile = oFM.GetFile(Fil ePath)
Response.AddHea der "Content-Size", oFile.Size
oFileUp.Transfe rFile FilePath

(where I retrieve get the file size)

In ASPSmartUpload, I have no trouble what-so-ever with ANY browser I try
using their download feature.
I use the download feature to grab a file that cannot be accessed via a URI,
so simply using the URI is not an option.

I checked and rechecked my variables "FilePath" and "FileName" and they are
exactly correct (if they weren't, I suppose I would have had an error!).
FilePath="e:\se curefiles\" and FileName="testf ile.zip"
I also monkeyed around with just about every MIME type their is with the
same results.

Here are the specs:
Server: W2K Server SP4
IIS: version 5.0

Anyway, I would just like to simply see an actual, working and tested
example for IE6, NN7.x, and Opera 6 + with
IIS version 5 running on Win2000 Server SP4.

Thanks!

Dave
Jul 19 '05 #1
1 7196
Answering my own question:

With the exception of Netscape 7 not automatically determining MIME type
(I'll have to put a browser test in for this version),
I have rewritten the code. I have discovered that they had FilePath where
they should have had FullPath. The order in which
object instantiation is also critical. After some experimentation , I have
come up with the following working and tested code:
Note: "FullPath" is something like "d:\myfolder\se curefiles\myfil e.arj" -
that is the entire tree including the file name.
'create instance of the SA FileManager
Set oFM = Server.CreateOb ject("SoftArtis ans.FileManager ")

'create instance of a file object
Set oFile = oFM.GetFile(Ful lPath)

' this header allows the download box to indicate size and bytes left
Response.AddHea der "Content-Size", oFile.Size

'this sets the MIME type to one that most browsers can use (necessary for IE
5.x) - forces dialog
Response.Conten tType = "applicatio n/x-msdownload"

set oFile = nothing
set oFM = nothing

'create this object instance last
Set oFileUp = Server.CreateOb ject("SoftArtis ans.FileUp")

'ensures the correct file name will show up in the save as dialog
Response.AddHea der "Content-Disposition", "attachment;Fil eName=""" &
FileName & """"

'does the actual xfer
oFileUp.Transfe rFile FullPath

'clean up
set oFileUp = nothing
I hope this is useful to someone else besides me and saves someone lots of
headaches.

Sin.
Dave

-@^@-
(_)
~__~
'''

"Dave" <dave[removethis]@miraclecat.com > wrote in message
news:3f******** **@news.iglou.c om...
Hi Everyone,

I was wondering if anyone has ever successfully used SA-FileUp's download
feature. I am being forced to change from
"ASPSmartUpload " as the server I am moving everything to is using SAFileUp version 3.2.
I ran through their documentation and found a section called "secure
download", unfortunately, their examples do not work
at all!
On Netscape 7, the file "pretends" to download (after changing the file
extension), but only an empty file is created.
On IE 6, I simply get an Internal Server Error (when calling the
TransferFile method of my object).

Here is the code (verbatim from the documentation):

Set oFileUp = Server.CreateOb ject("SoftArtis ans.FileUp")
Response.Conten tType = "applicatio n/x-msdownload"
Response.AddHea der "Content-Disposition", "attachment;Fil eName=""" &
FileName & """"
oFileUp.Transfe rFile FilePath

I also tried:

Set oFileUp = Server.CreateOb ject("SoftArtis ans.FileUp")
Response.Conten tType = "applicatio n/x-msdownload"
Response.AddHea der "Content-Disposition", "attachment;Fil eName=""" &
FileName & """"
Set oFM = Server.CreateOb ject("SoftArtis ans.FileManager ")
Set oFile = oFM.GetFile(Fil ePath)
Response.AddHea der "Content-Size", oFile.Size
oFileUp.Transfe rFile FilePath

(where I retrieve get the file size)

In ASPSmartUpload, I have no trouble what-so-ever with ANY browser I try
using their download feature.
I use the download feature to grab a file that cannot be accessed via a URI, so simply using the URI is not an option.

I checked and rechecked my variables "FilePath" and "FileName" and they are exactly correct (if they weren't, I suppose I would have had an error!).
FilePath="e:\se curefiles\" and FileName="testf ile.zip"
I also monkeyed around with just about every MIME type their is with the
same results.

Here are the specs:
Server: W2K Server SP4
IIS: version 5.0

Anyway, I would just like to simply see an actual, working and tested
example for IE6, NN7.x, and Opera 6 + with
IIS version 5 running on Win2000 Server SP4.

Thanks!

Dave

Jul 19 '05 #2

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

Similar topics

8
2559
by: JIMMIE WHITAKER | last post by:
Can someone help on this: I am just learning, and I'm connecting to the the northwindcs.mdf tables / open file is northwindcs.adp. This is the sample installed using msde, which is supposed to be mini sql server to learn. Please don't refer me elsewhere, here is what I'm trying to learn: If I want to hit a command button and do the...
2
1721
by: HazBin | last post by:
Folks, Sorry 'bout this. I'm sure it must be an FAQ, but I can't find the answer after many hours of looking :-( I don't know the SA password any more. Is there a mechanism for setting (or resetting) this to a known value? My assumption is that the encryption is sufficiently strong that it can't be discovered from viewing the data ? ...
1
6221
by: patrickshroads | last post by:
I just started a new job and no one seems to know the SA password. Here's my plan to change it: 1. I've run a trace for a couple of days to verify that there are no jobs or processes that are connecting as SA and that would break if I changed the password. 2. Before the changing the password I am going to bulk copy out the sysxlogins row...
2
2777
by: googlemike | last post by:
On the latest SQL 6.5 with the latest SQL 6.5 service pack, what's the trick to creating an account besides sa that has the power to create databases? I was thinking of calling this account 'sa2'. Why do this? Well, my boss asked me to do it because of a SOX audit + SAS-70 audit kind of thing. I tried using the GUI to do it, but then when...
1
5897
by: liorhal | last post by:
is there a difference in the previleges of 'sa' login and other login with 'sysadmin' role (and 'db_owner' for all databases) ? can they do the exact same things ?
8
1313
by: oaksong | last post by:
I had a web page that worked very nicely until I changed the SA password. The page used data widgets for connectivity to SQL server. I changed the password in the Server Explorer link, but the code gets to the .fill method and gives me an error that SA can't login. I've now spent several hours futzing with the widgets, reconnecting to the...
2
1257
by: Les Caudle | last post by:
I un-installed SQL 2000 developer's edition and installed SQL 2005 developer's edition in mixed mode security with the exact same sa password. I then attached my old databases. Even thought the web server is located on the same machine, I can no longer us the sa user/pass in my connection strings. The Open fails with what seems like a...
4
15640
by: BD | last post by:
Hi all. Running SQL2K SP4 on W2K3 Standard, SP4. I have just refreshed a database on one server with a backup from another. The database had existed previously on the target server, and I am just refreshing its contents. I used the following approach 1) From the target server, create a SQL script with users and roles 2) From the source...
2
2121
by: Bill E. | last post by:
We have renamed the 'sa' account on a SQL Server 2005 machine. When we run SELECT * FROM syslogins it appears that 'sa' no longer exists as a valid SQL login. However, when we look at running processes through sp_who, we see that 'sa' is still being used in various background operations, even when we shut down and restart the SQL...
3
2156
by: =?Utf-8?B?Ri5OLlo=?= | last post by:
I want to install SQL express edition on a laptop with vista home basic, but I faced a lot of problems.I have this error: SQL Setup could not connect to the database service for server configuration. The error was: Login failed for user 'sa'.refer to server error logs ans setup logs for more information. I went to Microsoft 'help and...
0
7912
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7839
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8202
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7959
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
1
5710
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5390
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3865
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1449
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1180
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.