<%
@ Register Assembly="Telerik.Web.UI, Version=2009.1.527.20, Culture=neutral, PublicKeyToken=121fae78165ba3d4"
Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
to my new form to work out telerik control. But i am facing the follwing issues
1) I cannot drag and drop the telerik control from tool box
2) suppose i manually add control by code by griving tagprefix name like <telerik:RadGrid ID="Grid1" runat="server"></telerik:RadGrid>
After i try to run the project i am getting the following error eventually. I dont know what is the reason
"The type or namespace name 'Telerik' could not be found in the global namespace (are you missing an assembly reference?) "
I tried 'gacutil' command tool to register the dll and also added the following block of code in web,config
<
assemblies>
<
add assembly="Telerik.Web.UI, Version=2009.1.527.20, Culture=neutral, PublicKeyToken=121FAE78165BA3D4"/>
But no use...the error still comes...What step i need to be taken to avoid the foloowing issues.
-Thanks
| <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="zzz.ascx.cs" Inherits="xxx.Modules.yyy.zzz" %> |
| <%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %> |
| <telerik:RadScriptBlock runat="server" ID="RadScriptBlock1"> |
| <script type="text/javascript"> |
| //<![CDATA[ |
| function formatWeekName(rawDate) |
| { |
| var dayofWeek = ''; |
| switch (rawDate.getDay()) { |
| case 0: |
| dayofWeek = 'Sunday'; |
| break; |
| case 1: |
| dayofWeek = 'Monday'; |
| break; |
| case 2: |
| dayofWeek = 'Tuesday'; |
| break; |
| case 3: |
| dayofWeek = 'Wednesday'; |
| break; |
| case 4: |
| dayofWeek = 'Thursday'; |
| break; |
| case 5: |
| dayofWeek = 'Friday'; |
| break; |
| case 6: |
| dayofWeek = 'Saturday'; |
| break; |
| default: |
| dayofWeek = ''; |
| } |
| return dayofWeek; |
| } |
| function formatMonthName(rawDate) |
| { |
| var monthName = ''; |
| switch (rawDate.getMonth()) { |
| case 0: |
| monthName = 'January'; |
| break; |
| case 1: |
| monthName = 'February'; |
| break; |
| case 2: |
| monthName = 'March'; |
| break; |
| case 3: |
| monthName = 'April'; |
| break; |
| case 4: |
| monthName = 'May'; |
| break; |
| case 5: |
| monthName = 'June'; |
| break; |
| case 6: |
| monthName = 'July'; |
| break; |
| case 7: |
| monthName = 'August'; |
| break; |
| case 8: |
| monthName = 'September'; |
| break; |
| case 9: |
| monthName = 'October'; |
| break; |
| case 10: |
| monthName = 'November'; |
| break; |
| case 11: |
| monthName = 'December'; |
| break; |
| default: |
| monthName = ''; |
| } |
| monthName = monthName + ' ' + rawDate.getDate(); |
| return monthName; |
| } |
| function formatTime(rawDate) |
| { |
| var hours = rawDate.getHours(); |
| var minutes = rawDate.getMinutes(); |
| var ampm; |
| if (hours >= 12) { |
| hours -= 10; |
| ampm = " PM"; |
| } |
| else { |
| ampm = " AM"; |
| } |
| if (minutes < 10) { |
| minutes = "0" + minutes; |
| } |
| return hours + ":" + minutes + ampm; |
| } |
| function onAppointmentClick(sender,eventArgs) |
| { |
| var appointment = eventArgs.get_appointment() |
| var subject = appointment.get_subject(); |
| var rawEndDate = appointment.get_end(); |
| var rawStartDate = appointment.get_start(); |
| var endDateTime = formatWeekName(rawEndDate) + ", " + formatMonthName(rawEndDate) + " at " + formatTime(rawEndDate); |
| var startDateTime = formatWeekName(rawStartDate) + ", " + formatMonthName(rawStartDate) + " at " + formatTime(rawStartDate); |
| var fbtWin = $find("<%= RadWindow1.ClientID %>"); |
| fbtWin.show(); |
| fbtWin.get_contentFrame().contentWindow.innerHTML = "HELLO WORLD"; |
| fbtWin.hide(); |
| fbtWin.show(); |
| } |
| function onAppointmentClickDock(sender,eventArgs) |
| { |
| var appointment = eventArgs.get_appointment() |
| var subject = appointment.get_subject(); |
| var rawEndDate = appointment.get_end(); |
| var rawStartDate = appointment.get_start(); |
| var endDateTime = formatWeekName(rawEndDate) + ", " + formatMonthName(rawEndDate) + " at " + formatTime(rawEndDate); |
| var startDateTime = formatWeekName(rawStartDate) + ", " + formatMonthName(rawStartDate) + " at " + formatTime(rawStartDate); |
| var dock = $find("<%= RadDock1.ClientID %>"); |
| var viewPort = $telerik.getViewPortSize(); |
| var xPos = Math.round((viewPort.width - parseInt(dock.get_width())) / 2); |
| var yPos = Math.round((viewPort.height - parseInt(dock.get_height())) / 2); |
| $telerik.setLocation(dock.get_element(), { x: xPos, y: yPos }); |
| var content = dock.get_contentContainer(); |
| content.innerHTML = "<table width='100%' border='0'><tr><td style=' font-weight:bolder'>Start:</td><td>" + startDateTime + "</td></tr><tr><td style=' font-weight:bolder'>End:</td><td>" + endDateTime + "</td></tr><tr><td style=' font-weight:bolder'>Description:</td><td>" + subject + "</td></tr></table>"; |
| dock.set_closed(false); |
| } |
| //]]> |
| </script> |
| </telerik:RadScriptBlock> |
| <telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server"> |
| <AjaxSettings> |
| <telerik:AjaxSetting AjaxControlID="RadScheduler1"> |
| <UpdatedControls> |
| <telerik:AjaxUpdatedControl ControlID="RadScheduler1" /> |
| <telerik:AjaxUpdatedControl ControlID="RadDock1" LoadingPanelID="RadAjaxLoadingPanel1" /> |
| </UpdatedControls> |
| </telerik:AjaxSetting> |
| </AjaxSettings> |
| </telerik:RadAjaxManagerProxy> |
| <telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" runat="server" Height="75px" |
| Width="75px" Skin="WebBlue" Transparency="20"> |
| <img alt="Loading..." src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' |
| style="border: 0px;" /> |
| </telerik:RadAjaxLoadingPanel> |
| <telerik:RadScheduler ID="RadScheduler1" runat="server" Height="460px" OnClientAppointmentClick="onAppointmentClick" EnableEmbeddedScripts="True" |
| HoursPanelTimeFormat="htt" Skin="Outlook" ValidationGroup="ctl00_RadScheduler1" |
| DataSourceID="SqlDataSource1" |
| DataEndField="End" |
| DataKeyField="ID" |
| DataRecurrenceField="RecurrenceRule" |
| DataRecurrenceParentKeyField="RecurrenceParentID" |
| DataStartField="Start" |
| DataSubjectField="Subject" OnAppointmentDataBound="RadScheduler1_AppointmentDataBound"> |
| </telerik:RadScheduler> |
| <telerik:RadDock ID="RadDock1" runat="server" DockMode="Floating" Closed="true" Skin="Outlook" Width="500px" Height="300px"> |
| <ContentTemplate> |
| </ContentTemplate> |
| </telerik:RadDock> |
| <telerik:RadWindow ID="RadWindow1" runat="server" AutoSize="True" Modal="True" Skin="Vista" > |
| </telerik:RadWindow> |
Hi,
Using RadControls for ASP.NET AJAX version 2007.3 1425 (Feb 25, 2008) and Internet Explorer 7 (version 7.0.5730.13), I am trying to paste a flash element in the RadEditor with the following clientside script:
var ieFilter = editor._filtersManager.getFilterByName("IEKeepObjectParamsFilter");
var ffFilter = editor._filtersManager.getFilterByName("MozillaKeepFlashString");
if (ieFilter) strXhtml = ieFilter.getDesignContent(strXhtml);
if (ffFilter) strXhtml = ffFilter.getDesignContent(strXhtml);
editor.pasteHtml(strXhtml);
Before this code is executed, the strXhtml variable contains the following xhtml:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" title="" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="8-165-o" xlink:title="Testflash"><param name="movie" value="/MediaFile.axd?Id=165&t=091027133557"></param><param name="quality" value="high"></param><param name="bgcolor" value="#FFFFFF"></param><embed src="/MediaFile.axd?Id=165&t=091027133557" quality="high" bgcolor="#FFFFFF" title="" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="8-165-o" xlink:title="Testflash" type="application/x-shockwave-flash" pluginspace="http://www.macromedia.com/go/getflashplayer"></embed></object>
The string that is passed to the pasteHtml method contains the following:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" title="" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="8-165-o" xlink:title="Testflash"><rade_param name="movie" value="/MediaFile.axd?Id=165&t=091027133557"></rade_param><param name="movie" value="/MediaFile.axd?Id=165&t=091027133557"></param><rade_param name="quality" value="high"></rade_param><param name="quality" value="high"></param><rade_param name="bgcolor" value="#FFFFFF"></rade_param><param name="bgcolor" value="#FFFFFF"></param><embed src="/MediaFile.axd?Id=165&t=091027133557" quality="high" bgcolor="#FFFFFF" title="" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="8-165-o" xlink:title="Testflash" type="application/x-shockwave-flash" pluginspace="http://www.macromedia.com/go/getflashplayer"></embed></object>
After this html is pasted I switch to html mode where I see the following:
<object codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" height="100" width="100" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" xlink:title="Testflash" xlink:href="8-165-o" xlink:type="simple" xmlns:xlink="http://www.w3.org/1999/xlink" href="null">
<param name="movie" value="/MediaFile.axd?Id=165&t=091027133557">
<param name="quality" value="high">
<param name="bgcolor" value="#FFFFFF"><embed src="/MediaFile.axd?Id=165&t=091027133557" quality="high" bgcolor="#FFFFFF" title="" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:href="8-165-o" xlink:title="Testflash" type="application/x-shockwave-flash" pluginspace="http://www.macromedia.com/go/getflashplayer"></embed></object>
When I postback the page and access the RadEditor's Content property this contains the same (except that the order of some attributes is different).
I see several differences between the content I originally pasted and the content that is posted:
- the title="" attribute has been removed from the <object> element (not a big problem).
- a href="null" attribute has been added to the <object> element (not a big problem though I doubt that this is comform the xhtml specification).
- the <param> tags are no longer closed. This is a problem since the content is not valid xhtml anymore, and I cannot parse it with an xml parser (which I need to do).
How can I solve this issue? Thanks for any help!

| <telerik:RadWindow ShowContentDuringLoad="false" VisibleStatusbar="false" ReloadOnShow="true" |
| NavigateUrl="../Client/ForecastsSelect.aspx" runat="server" ID="wndForecastSelect" Modal="true" |
| AutoSize="true" Animation="FlyIn" OnClientClose="OnForecastClose" Behaviors="Close"> |
| </telerik:RadWindow> |
| <telerik:RadGrid runat="server" DataSourceID="SqlDataSource1" GridLines="None" |
| ShowGroupPanel="True" AllowPaging="True"> |
| <MasterTableView datasourceid="SqlDataSource1"> |
| <RowIndicatorColumn> |
| <HeaderStyle Width="20px"></HeaderStyle> |
| </RowIndicatorColumn> |
| <ExpandCollapseColumn> |
| <HeaderStyle Width="20px"></HeaderStyle> |
| </ExpandCollapseColumn> |
| </MasterTableView> |
| <clientsettings allowdragtogroup="True"> |
| </clientsettings> |
| </telerik:RadGrid> |
Hi,
I would like to set the time interval in scheduler time slot,how can I achieve this?
Thanks
Sabarish
I want to click on child node and it show a RadWindow. But sometime i click on node and it show , and sometime not. I dont know what reason? Please Help me to solve this problem.Thanks. This is my code, i has tried to put this code into RadTreeView1_NodeDataBound.. but i cannot
protected
void RadTreeView1_NodeClick(object sender, RadTreeNodeEventArgs e)
{
e.Node.Attributes[
"onclick"] = String.Format("return ShowChannel('{0}');", e.Node.Value);
}