Upload image

N

Nagarajan

How to upload an image into my local harddisk if i am
using microsoft.visualstudio .net (latest) version
 
J

John Timney \(Microsoft MVP\)

You tend to upload to remote machines, locally you can just copy it. Joking
aside - upload is usually done via ASP.NET ( I assume you want to upload to
a web server) via a form type marked "multipart/form-data" as shown here.

<form action="fileupload.aspx"
method="post"
enctype="multipart/form-data"
runat="server">

<input id="MyFile" type="file" Size="47"
runat="server">

Once posted (following psotback) you can save the file locally

MyFile.PostedFile.SaveAs(newFileName);

Have a look in the help files for VS.NET, its all very well explained.


--
Regards

John Timney (Microsoft ASP.NET MVP)
----------------------------------------------
<shameless_author_plug>
Professional .NET for Java Developers with C#
ISBN:1-861007-91-4
Professional Windows Forms
ISBN: 1861005547
Professional JSP 2nd Edition
ISBN: 1861004958
Professional JSP
ISBN: 1861003625
Beginning JSP Web Development
ISBN: 1861002092
</shameless_author_plug>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top