Upload image

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Nagarajan

    #1

    Upload image

    How to upload an image into my local harddisk if i am
    using microsoft.visua lstudio .net (latest) version
  • John Timney \(Microsoft MVP\)

    #2
    Re: Upload image

    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="fileupl oad.aspx"
    method="post"
    enctype="multip art/form-data"
    runat="server">

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

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

    MyFile.PostedFi le.SaveAs(newFi leName);

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


    --
    Regards

    John Timney (Microsoft ASP.NET MVP)
    ----------------------------------------------
    <shameless_auth or_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_autho r_plug>
    ----------------------------------------------

    "Nagarajan" <srinarayanan_t @yahoo.com> wrote in message
    news:6f1801c344 b0$acf7f510$310 1280a@phx.gbl.. .[color=blue]
    > How to upload an image into my local harddisk if i am
    > using microsoft.visua lstudio .net (latest) version[/color]


    Comment

    Working...