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

*Urgent* How do open RadWindow From OnAppoinmentClick

3 Answers 38 Views
Window
This is a migrated thread and some comments may be shown as answers.
Luffy
Top achievements
Rank 1
Luffy asked on 30 Jun 2011, 08:46 PM
I have a urgent question to ask and i have problem doing it.

I have a rescheduler with Appointment on it, when i click on the appointment i want it to open RadWindow to display more information. However, i have no idea how it can be done at the server side. I have tried doing client side but it doesnt appear too.



<script type="text/javascript">
    function openwin() {
       
        var win = window.radopen('EventDetail.aspx', 'Details'); win.center();
     }

</script>

       <telerik:RadWindowManager runat="server" ID="RadWindowManager1">
            <Windows>
                <telerik:RadWindow runat="server" ID="Details" VisibleStatusbar="false" NavigateUrl="EventDetail.aspx"
                    Width="635px" Height="530px" AutoSize="false" Behaviors="Close,Move" ShowContentDuringLoad="false"
                    Modal="true">
                </telerik:RadWindow>
            </Windows>
        </telerik:RadWindowManager>
                                            <telerik:RadScheduler ID="RadScheduler1" runat="server" 
                                               AllowDelete="false" AllowInsert="false"   AllowEdit="False" DataDescriptionField="EventDesc"
                                                DataEndField="EventEndTime" DataKeyField="EventID" OnClientAppointmentClick="openwin()"
                                                DataSourceID="SqlDataSource1" DataStartField="EventStartTime" 
                                                DataSubjectField="EventTitle" DayEndTime="23:59:00"
                                                EditFormDateFormat="d/M/yyyy" EnableDescriptionField="True" Skin="Black" 
                                                
                                                style="z-index: 1; left: 210px; top: 34px; position: absolute; height: 425px; width: 861px" >
                                                <AdvancedForm DateFormat="d/M/yyyy" />
                                            </telerik:RadScheduler>

3 Answers, 1 is accepted

Sort by
0
Princy
Top achievements
Rank 2
answered on 01 Jul 2011, 06:34 AM
Hello Sherman,

By inspecting your code, I noticed the way you are calling the function for opening window is not correct. The RadControls has sender and arguments as its default parameters. It does not expect any extra arguments. So there is no need to call the function like normal controls.

aspx:
<telerik:RadScheduler ID="RadScheduler1" runat="server" OnClientAppointmentClick="openwin". . . . . . >

Thanks,
Princy.
0
Luffy
Top achievements
Rank 1
answered on 01 Jul 2011, 07:45 AM
I have set onclienappointmentclick to OnClientAppointmentClick="openwin". but it still doesnt work



<telerik:RadScheduler ID="RadScheduler1" runat="server" 
                                                DataDescriptionField="EventDesc" DataEndField="EventEndTime" 
                                                DataKeyField="EventID" DataSourceID="SqlDataSource1" 
                                                DataStartField="EventStartTime" DataSubjectField="EventTitle" 
                                               EnableDescriptionField="True"                                               
                                                style="z-index: 1; left: 210px; top: 34px; position: absolute; height: 425px; width: 861px" 
                                                Skin="Black" AllowDelete="False" AllowEdit="False" AllowInsert="False" OnClientAppointmentClick="openwin"
                                                EditFormDateFormat="d/M/yyyy" DayEndTime="23:59:00">
                                                <AdvancedForm DateFormat="d/M/yyyy" />
                                            </telerik:RadScheduler>
0
Marin Bratanov
Telerik team
answered on 01 Jul 2011, 12:42 PM
Hello Sherman,

You can find attached a sample page that works fine as you can see in the video I recorded in my test: http://screencast.com/t/cgNX3EyIks. I only had to change the databinding so that I can run the page. Please make sure that you have rebuilt your project after changing some server-side properties, especially if you are using a codeBehind and not a codeFile for the server-side code.


Best wishes,
Marin
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Window
Asked by
Luffy
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Luffy
Top achievements
Rank 1
Marin Bratanov
Telerik team
Share this question
or