This is a migrated thread and some comments may be shown as answers.

Kendo Upload is not working with Kendo Window

1 Answer 86 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
jalpesh.vadgama
Top achievements
Rank 2
jalpesh.vadgama asked on 17 Jun 2013, 07:25 AM
Hi,


I want to use Kendo upload into kendow window, but I am getting issue while uploading it. Below code for kendo upload in page.


ISSUE : I am getting multiple times response in "onSuccessWnd" function and also in my controller. So that same image will display multiple times. Please me solution for same.

It is working perfectly without window.


/********************** image.cshtml page  *********************/

@(Html.Kendo().Upload()
                  .Name("attachments")
                  .HtmlAttributes(new { id = "FilesToUploadWnd", style = "width:100%" })
                  .Messages(m => m.Select("select files from your computer… "))
                  .ShowFileList(false)
                  .Async(async => async
                            .Save("SaveWnd", "Log")
                        )
                  .Events(e => e
                            .Success("onSuccessWnd")
                          )
 
                )


/********************** javascript function  *********************/

function onSuccessWnd(e) {
 
        var url = "../FolderName/" + e.response.status.toString();
 
        var elem = document.createElement("img");
 
        elem.setAttribute("height", "70");
        elem.setAttribute("width", "70");
         
        elem.setAttribute("src", url);
 
        document.getElementById(appendID).appendChild(elem);
  
}
Please let know if any body have a solution for that.

1 Answer, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 19 Jun 2013, 07:24 AM
Hello,

Could you try to update the version you are using to the latest official one? There was a problem with the widgets multiple initialization when used in the Window content in older version that could cause this behavior.

Regards,
Daniel
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
General Discussions
Asked by
jalpesh.vadgama
Top achievements
Rank 2
Answers by
Daniel
Telerik team
Share this question
or