如何上传窗口应用程序并下载? [英] How to Upload a window application and download it?

查看:73
本文介绍了如何上传窗口应用程序并下载?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我开发了一个窗口应用程序。

我部署了它并完成了项目设置。



我的查询:

我在网上上传设置的方式和位置?

当用户开始点击下载应该开始的链接时,如何为设置创建下载链接?

I developed a window application.
I deployed it and I had the setup of the project.

My Query:
How and where shall I upload the setup in web?
How do i create a download link for the setup, when the user start clicking the link the download should starts?

推荐答案

我在网上如何以及在哪里上传设置?

完全取决于你 - 你可以将它发布到您自己的网站,或找到愿意展示的网站 - 可能值得关注您的应用程序实际所做的任何网站。



< b>如何为设置创建下载链接,当用户开始点击链接时,应该开始下载?

只需提供文件的链接:

"How and where shall I upload the setup in web?"
Totally up to you - you could post it to your own website, or find a site willing to show it - it might be worth looking at sites concerned with whatever it is your application actually does.

"How do i create a download link for the setup, when the user start clicking the link the download should starts?"
Just provide a link to the file:
<a href="http://myDomain.com/myfolder/myfile.ext" target="_blank">Human readable description</a>


下载按钮代码:



download button code:

string strURL = @"Jellyfish.jpg";
           WebClient req = new WebClient();
           HttpResponse response = HttpContext.Current.Response;
           response.Clear();
           response.ClearContent();
           response.ClearHeaders();
           response.Buffer = true;
           response.AddHeader("Content-Disposition", "attachment;filename=\"" + Server.MapPath(strURL) + "\"");
           byte[] data = req.DownloadData(Server.MapPath(strURL));
           response.BinaryWrite(data);
           response.End();





它将下载项目文件夹中的文件。



it will download the file present in your project folder.


这篇关于如何上传窗口应用程序并下载?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆