Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
25
Semicolon in file name
posted

Hello. I`d like to ask: did anyone experience problems uploading files with semicolon in the name of the files please? Our client has to upload files generated by other software that look like this for example: "hello;world.zip". Problem is that IG is using semicolon for parsing so file gets saved to server as "hello" and that`s all. We are able to find workaround when uploading just one file but in a case of multiple files with same beginning like "hello;world.zip" "hello;space.zip" it is a problem. is there someone experiencing this problem too please? did anyone find solution to this? Thank you in advance for help.

Parents
  • 23953
    Offline posted

    Hello David,

    I logged an internal issue with Development ID 213539 so that we can fix it in our codebase.
    I also created a case on your behalf with number CAS-169366-Z9S2H4 , so that you can be notified when there is a resolution for the issue.
    You can find your active cases under Account - Support Activity in our website. Select your ticket and go to Development Issues tab to view the status of related development issues.

    You can try to work around it by sending the file name separately as part of the request as described in this topic "Using Server-Side Events in ASP.NET MVC (igUpload)" section "Sending additional data between the client and server during file uploading". On the server you should rename the file with the correct name in the UploadFinished event.

    Here is an example code:

    On the client in JS:

     
    $("#upload1").on("iguploadonformdatasubmit", function (evt, ui) {
                $("#upload1").igUpload("addDataField", ui.formData, { "name": "fileName", "value": ui.fileInfo.file.name });
    });
    

    On the server in C#:

    public static void igUpload_UploadFinished(object sender, Infragistics.Web.Mvc.UploadFinishedEventArgs e)
    {
        var fileName = e.AdditionalDataFields[0].Value;
        System.IO.File.Move(e.FolderPath + e.FileName, e.FolderPath + fileName);
    }
    
    

    Best regards,
    Martin Pavlov
    Infragistics, Inc.

Reply Children
No Data