Resize image while uploading
<p>i am using file upload control for uploading images.
in that iam checking the condition,if Image.Width > 250 || Image.Height > 400 then i am resizing the image.
but it is giving the error 
"The SaveAs method is configured to require a rooted path, and the path 'ProductImages/roman_sandals.jpg' is not rooted."</p>

<p>ProductImages is folder where i am saving image.
Can anyone find why this is giving error,my code is</p>

<pre><code>string strBigServerPath = AppHardcodeValue.productImgPath;
            string strFileName = "";
            if (prodImg.HasFile)
            {
                strFileName = prodImg.PostedFile.FileName;
                string uniqueNum = Convert.ToString(System.Guid.NewGuid());
                string shortFileName = System.IO.Path.GetFileName(strFileName);
                string Extension = System.IO.Path.GetExtension(prodImg.FileName);
                string newFileName = shortFileName;
                prodImg.SaveAs(Server.MapPath(strBigServerPath + newFileName));
                using (System.Drawing.Image Img =
                   System.Drawing.Image.FromFile(Server.MapPath(strBigServerPath) + newFileName))
                {
                    if (Img.Width &gt; 250 || Img.Height &gt; 400)
                    {
                        Size MainSize = new Size(250, 400);
                        using (System.Drawing.Image ImgThnail =
                               new Bitmap(Img, MainSize.Width, MainSize.Height))
                        {
                            prodImg.SaveAs(strBigServerPath + newFileName);
                        }
                    }
                    Img.Dispose();
                }
                string ThumbnailPath = Server.MapPath(AppHardcodeValue.productThumbImgPath) + newFileName;
                using (System.Drawing.Image Img =
                    System.Drawing.Image.FromFile(Server.MapPath(strBigServerPath) + newFileName))
                {
                    Size ThumbNailSize = new Size(50, 50);

                    using (System.Drawing.Image ImgThnail =
                        new Bitmap(Img, ThumbNailSize.Width, ThumbNailSize.Height))
                    {
                        ImgThnail.Save(ThumbnailPath, Img.RawFormat);
                        ImgThnail.Dispose();
                    }
                    Img.Dispose();
                }

}
</code></pre>
