TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Dr.Ajay Kashyap
NA
521
285.2k
How to Rename and compress image in MVC
Dec 2 2016 11:02 PM
Hello..
How to Rename and compress image less than size when user upload image.
Given Below Is My Code Of Image Upload :-
if (ProfileImage != null)
{
if (ProfileImage.ContentLength > 0)
{
var fileName = Path.GetFileName(ProfileImage.FileName);
var path = Path.Combine(Server.MapPath("~/Upload"), fileName);
sud.ProfileImage = fileName;
ProfileImage.SaveAs(path);
ModelState.Clear();
}
}
Reply
Answers (
1
)
How to use Session In Mvc
open popup after page load