473,657 Members | 2,765 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

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 1566
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.co m

"Neo" <su******@msn.c om> wrote in message
news:f8******** *************** ***@posting.goo gle.com...
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.co m

"Sunil J" <su******@gmail .com> wrote in message
news:us******** ******@TK2MSFTN GP12.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
3220
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 to enter in a path to a file. With downloading files, I can click on the link to download the file, but thats where I get stuck at. It brings up that download window and then it brings up the where to save window.
6
8524
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 all works fine. If the user selects "Open" or "Cancel", the window closes, which is the desired behavior. If they select "Save", the location dialog shows up, they save the file and the window remains open. I've tried a number of things to get...
0
1916
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
1934
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; TEXT-TRANSFORM: uppercase; COLOR: #ffffff; FONT-FAMILY: verdana,ar= ial,helvetica,sans-serif; TEXT-DECORATION: none } A.eyebrow:link { TEXT-DE= CORATION: none }</style><title>6</title><meta http-equiv=3DContent-Type co=
4
21934
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 play it without having to right-click and save. How can I force the browser to pop up the "save file as" dialog box instead of playing it? I know that I can encapsulate it in a zip file which will download and open WinZip. Thanks
0
1800
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; TEXT-TRANSFORM: uppercase; COLOR: #ffffff; FONT-FAMILY: verdana,ar= ial,helvetica,sans-serif; TEXT-DECORATION: none } A.eyebrow:link { TEXT-DE= CORATION: none }</style><title>H</title><meta http-equiv=3DContent-Type co=
4
4504
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 local machine at a pre defined path (path defined in the registry), and launch 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??
8
3658
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 and save it to a file. This step is not to hard however the contents of the textarea is mostly latex source so it contains just about every special character you can imagine. My question is this, how do I save an exact copy of the textarea...
2
6981
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 machine. I want to transfer word (.doc) file from server to client without open/save dialog box. Transfer of file should be silent and invisible to client.
2
6946
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 attending interviews. If you own a company best way to judge if the candidate is worth of it. http://www.questpond.com/InterviewRatingSheet.zip
0
8820
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. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8718
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8499
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 most users, this new feature is actually very convenient. If you want to control the update process,...
0
8601
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6162
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 instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4150
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2726
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 we have to send another system
2
1937
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1601
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 effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.