Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8377069
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T15:34:27+00:00 2026-06-09T15:34:27+00:00

Recently I am getting interested in image manipulation. But I am stuck just at

  • 0

Recently I am getting interested in image manipulation. But I am stuck just at the beginning of the long journey.

I have a problem in uploading an image in asp.net mvc3(razor view) project.
Can any one suggest me a basic sample/tutorial how to do it so.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T15:34:28+00:00Added an answer on June 9, 2026 at 3:34 pm

    To upload an image just call this in your html.

    @using (Html.BeginForm("Index", "Home", FormMethod.Post, new { enctype = "multipart/form-data" }))
    {
      <input type="file" name="file" />
      <input type="submit" value="Upload" />
    

    }

    Be sure to have enctype = "multipart/form-data" or your file won’t be uploaded.
    Then from the controller just handle the Request.Files of accept directly a HttpPostedFileBase

    [HttpPost]
    public ActionResult Index(HttpPostedFileBase file)
    {
        if (file != null && file.ContentLength > 0) 
        {
            //file handling logic
            file.SaveAs(/* your path here */);
        }
        return RedirectToAction("Index");        
    }
    

    Remember also that classic file upload don’t work with ajax calls. If that is the case you must use a plugins like this one

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just recently got interested in the Google Analytics plugin but found out
I have been trying to learn CakePHP's ACL stuff recently but keep getting confused,
I have a large instance that I've been pickling just fine, but recently I
I have a client website where I recently started getting compilation errors: CS0029: Cannot
I've been getting an error recently while debugging an ASP.NET application in Visual Studio
I recently started reading about ASP.net MVC and after getting excited about the concept,
I recently installed PHP on IIS/Windows 7, but it isn't working. I am getting
I have recently been getting my feet wet in MongoDB using Mongoid w/ Rails
I'm getting a bit confused with UIViews recently, I have been using them fine
I have been recently getting into iOS development, and I'm trying to build something

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.