手动上传特定路径的文件asp.net [英] uploading file from specific path manually asp.net
问题描述
我正在尝试制作一个多上传代码。
有两个按钮:
add:将fileupload中的文件添加到列表中。
upload:从列表中上传所有文件。
在列表中我是保存:
Vale =文件名。
FullPath =来自客户端的完整路径。
和我想将它们从列表中的FullPath上传到某个文件:
I am trying to make a multiupload code.
with two button :
add : to add the file from fileupload to a list.
upload : to upload all the file from the list.
in the list i am saving :
Vale = the file name.
FullPath = full path from the client side.
and i want to upload them from the FullPath in the list to some file :
String _dest = "~/upload/";
foreach (FileListType _temp in FileList )
{
FileUpload _file = new FileUpload();
}
protected List<FileListType> FileList { set; get; }
protected struct FileListType
{
public String Value { set; get; }
public String FullPath { set; get; }
}
但实际上我不知道如何继续:
我的想法是构建一个新的fileupload并从列表中为每个元素提供路径并使用该fileuploader上传它
但是怎么能我将我的文件路径添加到fileuploader?
任何人都可以帮助我或引导我在哪里搜索?
but actually i don't know how to continue :
my idea is to build a new fileupload and give them the path from the list for each element and upload it using that fileuploader
but how can I add my file path to the fileuploader ?
any one can help me or lead me where i can search ?
推荐答案
上的路径客户端不会被发送到服务器 - 获取完整路径来自ASP.Net中的FileUpload控件 [ ^ ]。
只是文件将被传输。
The path on the client side will not be sent to the server - Get Full Path from FileUpload control in ASP.Net[^].
Just the file will be transferred.
这篇关于手动上传特定路径的文件asp.net的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!