Re: A few questions..

  •  01-20-2012, 3:31 PM

    Re: A few questions..

    Actually, I am doing that....
    1. protected void Uploader1_FileUploaded(object sender, CuteWebUI.UploaderEventArgs args)  
    2.     {  
    3.         System.Drawing.Image postedImage = System.Drawing.Image.FromStream(args.OpenStream());  
    4.           
    5.   
    6.         Session["ImageHeight"] = postedImage.Height.ToString();  
    7.         Session["ImageWidth"] = postedImage.Width.ToString();  
    8.   
    9.         string OrigFilename = Path.GetFileName(args.FileName);  
    10.         string OrigExtention = OrigFilename.Substring(OrigFilename.Length - 4, 4);  
    11.   
    12.         System.Guid newGUID = System.Guid.NewGuid();  
    13.   
    14.         string UploadedImageDir = Server.MapPath("UploadedImages/");  
    15.   
    16.   
    17.         string GUIDFilename = newGUID.ToString() + OrigExtention;  
    18.         string PathAndFileToUploadedImagesDir = UploadedImageDir + GUIDFilename;  
    19.   
    20.           
    21.         args.MoveTo(PathAndFileToUploadedImagesDir);  
    22. }  
View Complete Thread