Open kendo window in new browser window/tab

4 posts, 0 answers
  1. syian
    syian avatar
    12 posts
    Member since:
    Mar 2020

    Posted 22 Apr 2020 Link to this post

    I have a button on a tabstrip which onclick clones the active tab in a new kendoWindow. The problem is, that I need a new browser window, not a Kendo one.
    I tried the following:
    ...                           
    var clonedwin = jq(tab).clone().kendoWindow({ 
       title:     title,
       actions:   ["Close"],
       modal:     false,
       width:     "50%",
       height:    "600px",
       visible:   true,
       draggable: true,
       resizable: false,
       position: {
        top:  "10%",
        left: "30%"
       }                               
    }).data("kendoWindow");
     
    var win = window.open(clonedwin,"_blank","left=200,top=235,width=815,height=470,scrollbars=auto");

    ...

     

    The result is a new window with the error: "Unable to find web object file '[object Object]'" plus a new KendoWindow with the content from the tab.

    Thank you in advance, 
    Syian


  2. Veselin Tsvetanov
    Admin
    Veselin Tsvetanov avatar
    1235 posts

    Posted 24 Apr 2020 Link to this post

    Hi Syian,

    I have implemented the following Dojo sample, based on a suggestion form a StackOverflow thread:

    https://stackoverflow.com/a/19078591

    Note that you will need to pass the new Window content as an HTML string to the innerHTML property of its body:

    win.document.body.innerHTML = tab;

    As you need to open a new browser window, you won't need to initialize the Kendo Window itself at all.

    Regards,
    Veselin Tsvetanov
    Progress Telerik

    Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
    Our thoughts here at Progress are with those affected by the outbreak.
  3. syian
    syian avatar
    12 posts
    Member since:
    Mar 2020

    Posted 24 Apr 2020 in reply to Veselin Tsvetanov Link to this post

    Hi Veselin, 

    thanks for the response. 

    What you described is how in general the window.open works, which I already included in my original post. I was maybe not clear enough.. The goal is to create a new browser window and to load the Kendo element from the screen I am currently in.
    It comes down to if it is possible to pass a Kendo element - in this case the cloned kendoWindow - as an HTML string. 

    I tried the way you described:

    var win = window.open("","_blank","left=200,top=235,width=815,height=470,scrollbars=auto");

    win.document.body.innerHTML = clonedwin;

    which gives me the attached screen that shows [object Object].

    Regards, 
    Syian

  4. Veselin Tsvetanov
    Admin
    Veselin Tsvetanov avatar
    1235 posts

    Posted 28 Apr 2020 Link to this post

    Hello Syian,

    I am afraid that is is not possible to move a Kendo widget from one browser window to another. Hence, the result observed is expected.

    Regards,
    Veselin Tsvetanov
    Progress Telerik

    Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
    Our thoughts here at Progress are with those affected by the outbreak.
Back to Top