473,322 Members | 1,671 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

download a file in a background without Save As

Neo
Hello,

I have a requirement wherein, a user clicks on a file name in a
ASP.NET web application, and the file should automatically be
downloaded in the local machine at a pre defined path (path defined in
the registry), and open the file in its associated application.

I think this can be done through ActiveX Controls, but i dont know how
to create ActiveX controls in .NET??

Can anyone give me any suggestions as to how one can achieve this??

Thanks in advance for help

Cheers

Sunil
Nov 16 '05 #1
3 1554
Neo,

You can't create ActiveX controls in .NET (well, you can, but the method
is unsupported, and I wouldn't recommend it).

You can run a .NET control in internet explorer, and then have that
perform the download. However, when you run .NET controls in IE, the setup
for such controls needs to elevate the permissions for that control.

For more information on how to host a control in IE, check out the
article titled "Using Windows Forms Controls in Internet Explorer" on the
gotdotnet site, located at (watch for line wrap):

http://samples.gotdotnet.com/quickst...eSourcing.aspx

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Neo" <su******@msn.com> wrote in message
news:f8**************************@posting.google.c om...
Hello,

I have a requirement wherein, a user clicks on a file name in a
ASP.NET web application, and the file should automatically be
downloaded in the local machine at a pre defined path (path defined in
the registry), and open the file in its associated application.

I think this can be done through ActiveX Controls, but i dont know how
to create ActiveX controls in .NET??

Can anyone give me any suggestions as to how one can achieve this??

Thanks in advance for help

Cheers

Sunil

Nov 16 '05 #2
Hello Nic,

Thanks for the speedy reply.

My doubt is like in Windows form, i can access the registry of the
machine where the application is running and get the file store path
from the registry. Whereas In case of using windows form controls in IE
(.NET Control), can i access the the target machine registry??

I am not sure i can do that even if there are lowest possible
permissions applied in that machine.

I will look at that article and try somethings out.
Thanks for the same.

I have created a stand alone Windows application do the things which i
said in my previous mail, is that possible from a Web control is my
Question?

Any more suggestions in getting the thing solved, are more than
appreciated. Thanks once again

Cheers

Sunil Jambekar

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #3
Sunil,

Chances are you will not be granted the right to access the registry.
In order to embed a .NET control in IE, you will have to set the security
permissions on the machine that is installing it. If you don't have control
over the machines in the environment this will run, then this probably isn't
the best solution for you and you should resort to an ActiveX control using
unmanaged code.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Sunil J" <su******@gmail.com> wrote in message
news:us**************@TK2MSFTNGP12.phx.gbl...
Hello Nic,

Thanks for the speedy reply.

My doubt is like in Windows form, i can access the registry of the
machine where the application is running and get the file store path
from the registry. Whereas In case of using windows form controls in IE
(.NET Control), can i access the the target machine registry??

I am not sure i can do that even if there are lowest possible
permissions applied in that machine.

I will look at that article and try somethings out.
Thanks for the same.

I have created a stand alone Windows application do the things which i
said in my previous mail, is that possible from a Web control is my
Question?

Any more suggestions in getting the thing solved, are more than
appreciated. Thanks once again

Cheers

Sunil Jambekar

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 16 '05 #4

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

Similar topics

10
by: scrimp | last post by:
Ive been using PAMIE 1.4 to try to automate web page processes. The one thing I cannot do with it is upload files and download files. With uploading files, the file input box does not allow PAMIE...
6
by: chon | last post by:
I have an ASP page that is sent a file location as a parameter. It opens this file, loads the ADODB.Stream object and does a binary write to the page forcing the download dialog to appear. This...
0
by: Sarah Akers | last post by:
GgF ----gL5cJ72EqiGIQ0SK65Rz Content-Type: text/html; Content-Transfer-Encoding: quoted-printable <html> <head> <style type=3D"text/css">.eyebrow { FONT-WEIGHT: bold; FONT-SIZE: 10px; TE=
0
by: Anne Snow | last post by:
7qs ----bSCMEc0pLIbJxmV9 Content-Type: text/html; Content-Transfer-Encoding: quoted-printable <html><head><style type=3Dtext/css>.eyebrow { FONT-WEIGHT: bold; FONT-SIZE= : 10px;...
4
by: Kevin Muenzler, WB5RUE | last post by:
How do I force a browser to download a file instead of displaying it? In other words I have a page with MP3 and WMA files on it and I would like for the visitor to download the file instead of...
0
by: Lynda Kilgore | last post by:
jGu ----qtHwhORV90yyhqJMOc Content-Type: text/html; Content-Transfer-Encoding: quoted-printable <html><head><style type=3Dtext/css>.eyebrow { FONT-WEIGHT: bold; FONT-SIZE= : 10px;...
4
by: sunilj20 | last post by:
Hello, I have a requirement wherein, a user clicks on a file name in an ASP.NET web application, and the file should automatically be downloaded (Without showing the "Open", "Save As") in the...
8
by: david.lindsay.green | last post by:
Hello all, I am quite new a web scripting and making web pages in general and I have stumbled across a problem I have as yet been unable to solve. I am trying to take the contents of a textarea box...
2
by: Jay | last post by:
Hi, I have some unique situations where i need to transfer a file from Server to client but without any Open or Save dialog box shown to the user. The file should save itself directly to client...
2
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.