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

Second Window not initializing correctly

2 Answers 117 Views
Window
This is a migrated thread and some comments may be shown as answers.
Kashim
Top achievements
Rank 1
Kashim asked on 08 May 2012, 09:08 AM
Hi 
I have created a simple textinput widget with a button. When the button is clicked a window (with a combobox is created). The combobox is initialized correctly. However, when I declare a second textinput widget, the combobox does not initialize. 

I've searched around the forums but can't find any answers. I have created a simple test app to demonstrate the problem.

Any help would be appreciated.

Kashim

2 Answers, 1 is accepted

Sort by
0
Kashim
Top achievements
Rank 1
answered on 08 May 2012, 11:10 AM
I have found a way round my problem. I just destroy() the popup window, during the close event. 

The code in my textinput widget's openWindow() function is now
like this

// Always create a kendoWindow .....before I only initialized the once
that.mywindow = $("<div />").kendoWindow({
                width: "250px",
                height: "100px",
                close: function (e) {
                    // reset global var 'global1' and destroy window
                    global1 = "";
                    this.destroy(); 
                },
                modal: true
            });
0
Neo Wong
Top achievements
Rank 1
answered on 30 May 2012, 09:50 AM
Thanks Kashim

your post is very helpful , I just met the same problem 
Tags
Window
Asked by
Kashim
Top achievements
Rank 1
Answers by
Kashim
Top achievements
Rank 1
Neo Wong
Top achievements
Rank 1
Share this question
or