multiple file upload using my web form

Hi all.

I work for a web company, and a website was built for a client, which lets the company that we built it for, upload images to their web server through the web page using a standard fileupload control. For each image they upload, some code in the background (vb .net) takes the details and adds the details to a database on the server, the loads the image to the server. On a regular basis they upload all their images this way, which can be hundreds of images!

Is there a way for me to let them upload a folder full of images? This couldn't be an FTP job as code needs to work in the background as well. I read that you can use Directory.GetFiles to get a list of all files in a directory, but this seems to only work for local folders, not from a client machine folder to a webserver folder. I assume this would be a security restriction on ASP.net's part.

Is there a way round this? Is there even a way to let them select multiple files in the file upload control? So in the screen where they choose an image file, they could hold down control key and select more files? Or a way just for them to select folder name, and I could upload all files in it?

Thanks, Paul.

0
pauldavidson
7/17/2008 4:14:31 PM
asp.net.web-forms 93655 articles. 5 followers. Follow

3 Replies
968 Views

Similar Articles

[PageSpeed] 12

For this solution what I did was allow them to upload a zip file which then I programatically unpacked in the folder then deleted any non image files that were included. (You can also limit what gets unpacked)

There are also multiple upload custom controls out there. I just had the problem like you where there were many many files that needed to be uploaded.

¤´¨)
¸.•´ ¸.•*´¨) ¸.•
(¸¸.•´ .•If you find my post helpful, please mark it.
Thanks! (¸¸.•´ ¸.•
(¸.¤
0
TonyG_
7/17/2008 4:33:06 PM

Hi,

I got this solution for you:

let them upload the images in a zip file (Compressed folder). You can use the open source SharpZipLib to unzip the file to a temporarly local folder on the server. You then traverse the folder using .NET files/directory methods and extract what ever information you need then you can take them to the location where you want them to be.

Regards


Don't forget to click (Mark as Answer) on the post that helped to solve your problem.
0
mr
7/17/2008 4:38:45 PM

thanks lads

the only multiplefile uploads I found, were putting more than one file upload control on screen, which defeats the point...

so ill have a look at this zip extractor,

cheers,

0
pauldavidson
7/17/2008 8:15:35 PM
Reply:

Similar Artilces:

can someone one give me difference between web form and mobile web form and which or where or when i'm using the forms?
thanks Marc Hi Marc, Based on my understanding, you want to know the differences between the ASP.NET web application and ASP.NET mobile web application. If I have misunderstood you, please feel free to let me know. The ASP.NET forms are used to develop the ASP.NET pages for desktop browsers and The ASP.NET mobile forms are used to develop the ASP.NET pages for mobile device browsers. When we create the ASP.NET mobile web forms pages, we can use nearly all the features of ASP.NET. But there are a couple of compatibility issues: Error Handling and Reporting. Tracing. Using Redi...

WEB FORMS and datasetS (do I have to repeat the file definition in every web form?)
I am working on vb.net.I have a project with 35 web forms and an access file with 18 tables.Until now I have defined the oledbadapters in every form by dragging the tables from the server explorer tool box.This is not a good idea because every time that I make a change on the database design I have to drag the new definition on 35 web forms and I have to create the datasets again. This is boring and time consuming!The question is:WHAT CAN I DO TO HAVE THE FILE DEFINITION ONLY IN ONE PLACE AND THAT EVERY WEB FORM WOULD TAKE THE DATA ADAPTERS AND DATASETS FROM THERE? how about if you write a...

Web forms and mobile web forms
Hey everyone, I am looking to develope a web site that depending on the device connecting to it, it will display a certain page. In this case im looking to create a web and wap version of the same project. I have the Web forms version finished using ASP.NET and C# and I am wondering how to create the mobile web form and incorporate it in the project. In the project folder, can I just add a mobile web??? But what about displaying device specific pages?? Cheers -Dudach Yes, you can add mobile web forms and controls to your Web Application project. No problem. For device/br...

How to Make Web Forms from other Web Forms
In putting together an ASP.NET application for a biz application, we have come to the point where there are three different types of basic forms which have, for the most part, been perfected. Now its is a matter of cloning those forms for various uses and modifying or adding code to suit the particular need. Copy and paste works OK, but there is a lot of changing of certain words, etc. Is there a way in ASP.NET to take these basic forms, turn them into classes or templates, create forms from them, then add or overwrite code? ? (Anybody who is a Vis Fox Pro programmer would know imme...

Need Windows Form to Retrieve Information From Web Form
I have a cash and carry web site that customers can order products, the next day come in to the company to pay and pickup. I would like to create a windows application for the company to do two things: 1. download all the orders from the day before 2. upload price changes, product changes, category changes I've search the internet and forums and the only thing I can find that I think would actually link these two together would be a web service. Can you please tell me if I am heading in the right direction or if there is another method to link the two applications, if there are any pitf...

Creating and using a common web form for multiple web sites
Hi.  I thank you in advance for the responses. I have a common web form ( a search/result database screen) that can be used throughout multiple web sites.  What is the best way to have this web form and codefile consumed by multiple applications?   Thanks   If these are truely different sites then that will mean they will have different processes. You will probably need to put these files into a DLL for distribution to each app. The other option (there may be more but these are the only two I can think of now) would be to have these driven by a webservice and feed t...

For interrupting.web form Resized by position of the div : if div can't dispaly all (such as only top part , then web form heithten the heght),resize the web form
Web Form Resized by position of the div : if div can't dispaly all (such as only top part , then web form heithten the heght),resize the web form ! Because of my pool English, if you can't see , I will explain more ! ThanksGambler is the real life I guess you mean when form grows it also grow parent div element. This is normal. If you want div to stay fixed size and rather clip the form and maybe show a scrollbar, look at overflow property in CSS.Thanks------------------------------------------------------------This posting is provided "AS IS" with no warranties, and confers no ...

Include web form inside web form
I tried to include an aspx file in a asp.net web form. However, all the web controls (textbox, button) in the included page are not displayed when called. <Form id="Form1" method="post" runat="server"> <%   Response.writeFile("subPage.aspx"); %> <asp:button id="btnPrev" runat="server" text="Previous"></asp:button> </Form> There are some <asp:textbox> controls in the subPage.aspx file, the file itself works fine, but when it is included in the main page, all the controls are not displayed. Please assist. Thanks   u should u...

Web Form embedded in another Web Form
Hi,  I have programmed a Web Form which acts like a scientific calculator. I would like to embedd this calculator in the upper left hand corner of another accounting Web Form. I don't want to host the calculator on the same server as the accounting page. I.e. I want them to have distinct URLs. Classically, I would do this using frames, but is there a better way using ASP? Is there some sort of Panel which can display the webpage at a specific URL which I can just drag onto my accounting Web Form? Thanks,  P1000   Frames are the only way to embed a webform inside ano...

How to fire events in other web form from other web form ?
Suppose that I have A and B web form. I want to trigger B web form's Page_Load event from A web form. How can I do that ? Thanks in advanced WilbertWilbert Bujn Create a public method in B that call the load method : public void Load(object sender, System.EventArgs e) { Page_Load(sender, e) ; } In the page_load of A, instanciate a B object and then call the function B myB = new B() ; myB.Load() ; Quicky Thank you quicky, it works fine. WilbertWilbert Bujn...

Web Form vs. Web Content Form
If you don't mind, I would like to know what is the difference between those two items, when I go to add a new item I see both of those and I don't know what the difference is.  A content form is for use with a masterpage. A web form is a standalone web page. If you select web content form, you will then have to specify a masterpage for it. and what is a master page used for?  Hi, a master page is used to give a constant look and theme to a site, without having to duplicate code. So basically you can put your header, menu, nav and footer on a master page. Then a...

calling a web form from another web form
I would like to know what is the best way to open a web form from another web form. I would like to call it from a button control. Thanks Well, if I've grasped your question right, there are many methods to do that: 1)Response.Redirect > To navigate to another page from code and is equal to clicking a hyperlink. I suggest this as I think it's closer to your question. 2)Server.Transfer > This ends the current web form and begins a new web form. It's usable when you want to pass some variables i.e (Label1.Text) to the next immediate page. It's not safe though and not used to send p...

C#.NET WEB APPLICATION
hei guys, i need help on my application, i'm using C#.NET as front-ed and SQL as back-end, aside from a datagrid, i want to display my data using textboxes and not a datagrid, i can do it using Visual Basic 6 but since i'm a newbee at C#.NET i don't know how to do it, specially the codes, can anyone help me with it? thank you in advance! If you are doing windows development, i would suggest using 'DataForm wizard' (Use Solution Explorer-->Rightclick project-->Add new Item-->New DataForm). It will guide you through steps. If you are doing web apps. Use quickstart to learn them. h...

Use web.config with web forms?
 Hi All, I'm doing some unit testing of a web application, and would like to use settings from a web.config file.  Is this possible? Thanks much,- Mark I'd suggest keeping your Unit Tests in a seperate project and using it's own .config file. It will be a little repetition but it will help to keep things seperated for perf and reusability without bloating your production app. I agree with Curt. It is better to seperate options for testing and release version. This will decrease the job to be done once the unit testing process is finished.Haissam Abdul Mal...

Web resources about - multiple file upload using my web form - asp.net.web-forms

Multiple sequence alignment - Wikipedia, the free encyclopedia
A multiple sequence alignment (MSA) is a sequence alignment of three or more biological sequences , generally protein , DNA , or RNA . In many ...

Police officer Daniel Holtzclaw guilty of raping multiple women
For months, accusers, authorities and now an Oklahoma jury say, police officer Daniel Holtzclaw preyed on vulnerable women.

James Deen's Porn Company Faces Workplace-Safety Probe After Multiple Rape Claims 0
The California watchdog agency tasked with ensuring safety in the workplace confirmed Wednesday it is investigating porn actor James Deen's production ...

Facebook Tweaks Power Editor for Users With Multiple Ad Accounts
Facebook rolled out a new feature for its Power Editor that should greatly speed up the process for users with multiple advertising accounts. ...

Apple Needs to Offer Own TV Content after Multiple ‘Speed Bumps,’ Says FBR
FBR & Co. analyst Daniel Ives this morning reflects on reports by Bloomberg and others that Apple ( AAPL ) has shelved an effort to create a ...

Google Ventures reportedly closed its European fund after multiple stalled deals
Earlier this week, Google Ventures announced it was closing down its dedicated European fund . It had been assigned $125 million to invest, but ...

Multiple McDonald’s Locations Forced To Close After Prank Callers Convince Workers To Test Fire System ...
When I think of prank calls, I conjure up images of teenage girls huddled around their clear plastic phones, calling boys in their class and ...

OKC Police Officer Found Guilty On Multiple Counts Of Raping Black Women
Former Oklahoma City Police officer Daniel Holtzclaw will be going to prison for a very, very long time. After deliberating for well over 45 ...

Cowboys Fan Beats Up Multiple Attackers In Parking Lot Brawl
That's the best defense anyone wearing a Tony Romo jersey has ever played

Report: Robert Nkemdiche Fell From A 4th-Story Window And Suffered "Multiple Cuts"
Probable top-five NFL draft pick and Ole Miss star Robert Nkemdiche reportedly fell from the 4th floor of a building, and suffered “multiple ...

Resources last updated: 12/17/2015 10:02:08 AM