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

[Solved] Get error when open rad window from another rad window

1 Answer 124 Views
Window
This is a migrated thread and some comments may be shown as answers.
NeilNguyen
Top achievements
Rank 1
NeilNguyen asked on 03 Dec 2007, 08:31 PM
I have a rad window (form2) opened from a main form (form1). From form2, I launch a normal dialog (form3) without using telerik control. In form3 I added a link to popup rad window, unfortunately i got error:

"Object doesnt support this property or method"

Here's my asp code in form3:

form3.aspx

<asp:LinkButton ID="lkbContact" Text="click here" runat="server" OnClientClick="OpenContactWindow(); return true;" />

function OpenContactWindow()

    //Error occured in this line
    var oWnd = window.radopen("AddNewContact.aspx", "addNewContactWindow");
}


form2.asp:
And my code in form2.aspx
        <radW:RadWindowManager
            id="radWindowManager"
            runat="server"                
            >
            <windows>
                <radW:RadWindow ID="addNewContactWindow"                                             
                    Runat="server"
                    Modal="true"
                    ReloadOnShow="True"
                    Width="580px"
                    Height="410px"
                    >
                </radW:RadWindow>
               
            </windows>                       
        </radW:RadWindowManager>         



Could anyone here tell me why i got this error?

thanks
Neil

1 Answer, 1 is accepted

Sort by
0
Georgi Tunev
Telerik team
answered on 05 Dec 2007, 01:27 PM
Hi Neil,

In general, if you want to use radopen() on some page, you must have the RadWindowManager declared there as well - otherwise the function will not work.

I am not sure what exactly you want to achieve - can you please elaborate some more on that? Do you want the RadWindow to be opened in the context of the topmost page or you want it to be in form3? If you want to open it in the context of form3, you will have to put a RadWindowManager on that page and then to call radopen(). Note that in this case the RadWindow will be restricted to that page only (form3).

If you want to open the RadWindow in the context of the topmost page (where I believe your RadWindowManager is), try using
top.radopen("AddNewContact.aspx", "addNewContactWindow")
This way you will refer the topmost page and since there you have a RadWindowManager, it will open a new  RadWindow.



Kind regards,
Georgi Tunev
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Window
Asked by
NeilNguyen
Top achievements
Rank 1
Answers by
Georgi Tunev
Telerik team
Share this question
or