Server Error in '/' Application.

Parameter is not valid.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentException: Parameter is not valid.

Source Error:


Line 243:            else if (!File.Exists(Server.MapPath("../uploads/users/profile/fb" + obj.UID.ToString() + ".jpg")))
Line 244:            {
Line 245:                Bitmap bmpStamp = new Bitmap(Server.MapPath("../uploads/users/Profile/" + OriImageName));
Line 246:                commonclass.AddStampToPhoto(obj.UID.ToString(), bmpStamp, obj.FullName.ToString(), obj.Occupation.ToString());
Line 247:                MetaimageName = configclass.siteUrl + "uploads/users/profile/fb" + obj.UID.ToString() + ".jpg";

Source File: c:\inetpub\vhosts\makeuonline.com\infoa2z.com\Community\ViewProfile.aspx.cs    Line: 245

Stack Trace:


[ArgumentException: Parameter is not valid.]
   System.Drawing.Bitmap..ctor(String filename) +623855
   Community_ViewProfile.FillDashbaord(Int64 CurUserID, String mode) in c:\inetpub\vhosts\makeuonline.com\infoa2z.com\Community\ViewProfile.aspx.cs:245
   Community_ViewProfile.Page_Load(Object sender, EventArgs e) in c:\inetpub\vhosts\makeuonline.com\infoa2z.com\Community\ViewProfile.aspx.cs:36
   System.Web.UI.Control.OnLoad(EventArgs e) +106
   System.Web.UI.Control.LoadRecursive() +68
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3785


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.7.4087.0