This topic contains 4 replies, has 2 voices, and was last updated by  saravananmra 11 years, 8 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • Window recreate #19923

    saravananmra
    Member

    Hi,
    I am unable to recreate the window.

    I have done the below,

    – When button (name is claim) is clicked, i am creating and opening a window (I have HTML close button in that window)
    – once clicked on the close button i am destrying and closing that window because once i closed this window i have to again call the same function(window’s create and open) when clicked on the button (button name is claim) again
    – now when button(button name is claim) is clicked again i am not able to recreate the window.

    Please suggest.

    Regards,
    M.Saravana kumar

    Window recreate #19935

    Peter Stoev
    Keymaster

    Hi,

    The window’s ‘destroy’ method removes the window from the DOM. If you want to ‘destroy’ it, then you will have to add a new DIV tag and then initialize a new window instance from it. Another option is to use the following approach: http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxwindow/defaultfunctionality.htm?web

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    Window recreate #19961

    saravananmra
    Member

    Hi Peter,
    Thanks for the quick reply and ur approaches.

    http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxwindow/defaultfunctionality.htm?web
    – here once the page loads, the window instialization is happening and also this window doesn’t have model true.

    But in my case, i need model:true.. If i use this approach with model:true the shadow is appearning once the page loads. Please suggest.

    I want to achieve the below using JQwidets,

    Whenever i click on the button i should open the window with model:true.
    whenever i close(HTML close button and also window close icon) the button i should close the same window.

    Regards,
    M.Saravana kumar

    Window recreate #20033

    Peter Stoev
    Keymaster

    Hi saravananmra,

    To disable the auto-open behavior, set the jqxWindow’s autoOpen property to false during the initialization.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com/

    Window recreate #20053

    saravananmra
    Member

    Hi Peter,
    Thanks for this solution for the issue 1
    Issue 2 is, how do we recall the window intialization for the second popup?

    My code is,

    $(‘#’+config.id).jqxWindow({
    showCollapseButton: true,
    theme: config.theme,
    resizable: config.resize,
    width: config.wdh,
    height: config.ht,
    isModal: config.modal,
    autoOpen: false
    });

    Where Config is a JSON object. It has id of the Div, theme name, resize etc..

    Please suggest as i am using this generic function for opening windows.

    Thanks in advance.

    Note:
    I don’t want to do the window intialization code again and again for each popup.

    Thanks,
    Saravana kumar

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.