AsyncUpload Locking files

4 posts, 0 answers
  1. Matthew
    Matthew avatar
    2 posts
    Member since:
    Apr 2013

    Posted 23 Jul 2013 Link to this post

    try
                {
                    string packageName = SSISPackages.SelectedItem.Text.Replace(" ", "_");
                    string packageDesc = SSISPackages.SelectedItem.Text;                
                    foreach (UploadedFile f in UploadFile.UploadedFiles)
                    {
                        f.SaveAs(AdministartiveToolManager.GetPackageLocation(packageName) + AdministartiveToolManager.GetFileName(packageDesc), true);
                    }
                    
                }
              
    My file is Lock after i ran the above code.... 

  2. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 26 Jul 2013 Link to this post

    Hi Matthew,

    Could you provide us with more information about your scenario? When do you execute this code? Usually the uploaded file is locked in cases, where it is being opened by another process or if the uploading is not finished.

    Regards,
    Hristo Valyavicharski
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Matthew
    Matthew avatar
    2 posts
    Member since:
    Apr 2013

    Posted 28 Jul 2013 Link to this post

    Hi Hristo
    Its called on the postback triggered by a button. using the asyncUpload to tranasfer file through the UI, which is processed by another application. Its locked before the application picks it up. Is there any way of ensuring the file is always unlocked.
  5. Hristo Valyavicharski
    Admin
    Hristo Valyavicharski avatar
    975 posts

    Posted 31 Jul 2013 Link to this post

    Hi Matthew,

    If the file is not being opened by the other application it shouldn't be locked. Please open a support ticket and attach a runnable sample with steps to reproduce, so we could look and debug your code.

    Regards,
    Hristo Valyavicharski
    Telerik
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Back to Top