Hello,
I try to migrate one of my custom webpart which use previously MOSSRadEditor in his version 4.5.3 with the new version 5.1.0.
It's difficult, because I used a lot of property, for example to specify path of images and other properties. These properties don't exist with the new version.
Do you have a guide or a documentation for this type of migration ?
Thanks in advance for your answer.
Best Regards.
Nicolas COLLET.
| function ScheduleMoved(sender, eventArgs) |
| { |
| var start = formatDate(eventArgs.get_newStartTime()); |
| var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>"); |
| var index = eventArgs.get_appointment().get_id(); |
| ajaxManager.ajaxRequest(index.toString() + '+' + start.toString()); |
| } |
What is the difference between :
RadControls for ASP.NET
and
RadControls for ASP.NET AJAX ?
Both work with Ajax.Net ?
Thank you in adance,


ASPX:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ClearCaching.aspx.cs" Inherits="Web_PersonnelInfoQuery_ClearCaching" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Sample Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
</div>
<telerik:RadAjaxPanel ID="myPanel" runat="server" LoadingPanelID="RadAjaxLoadingPanel1">
<telerik:RadDatePicker ID="RadDatePicker1" Runat="server" AutoPostBack="True"
onselecteddatechanged="RadDatePicker1_SelectedDateChanged">
<DateInput InvalidStyleDuration="100" autopostback="True"></DateInput>
</telerik:RadDatePicker>
</telerik:RadAjaxPanel>
<telerik:RadAjaxLoadingPanel ID="RadAjaxLoadingPanel1" Runat="server"
height="75px" Transparency="15" width="75px">
<img alt="Loading..."
src='<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>' originalAttribute="src" originalPath="<%= RadAjaxLoadingPanel.GetWebResourceUrl(Page, "Telerik.Web.UI.Skins.Default.Ajax.loading.gif") %>"
style="border:0px;" />
</telerik:RadAjaxLoadingPanel>
</form>
</body>
</html>
C#:
using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
public partial class Web_PersonnelInfoQuery_ClearCaching : BasePage
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void RadDatePicker1_SelectedDateChanged(object sender, Telerik.Web.UI.Calendar.SelectedDateChangedEventArgs e)
{
// do something here
string s = string.Format("this is {0} test", "a");
s += "!";
}
}
Note that we make Web_PersonnelInfoQuery_ClearCaching inherited from BasePage, and the code of BasePage is quite simple.
BasePage:
using System;
using System.Data;
using System.Configuration;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.IO;
using System.Text.RegularExpressions;
using System.Text;
public class BasePage : Page
{
protected override void Render(HtmlTextWriter writer)
{
StringWriter stringWriter = new StringWriter();
HtmlTextWriter htmlWriter = new HtmlTextWriter(stringWriter);
base.Render(htmlWriter);
string html = stringWriter.ToString();
MatchCollection collection = Regex.Matches(html, "<(a|link|img|script|input|form).[^>]*(href|src|action)=(\\\"|'|)(.[^\\\"']*)(\\\"|'|)[^>]*>", RegexOptions.IgnoreCase);
foreach (Match match in collection)
{
if (match.Groups[match.Groups.Count - 2].Value.IndexOf("~") != -1)
{
string url = this.Page.ResolveUrl(match.Groups[match.Groups.Count - 2].Value);
html = html.Replace(match.Groups[match.Groups.Count - 2].Value, url);
}
}
#endregion
writer.Write(html);
}
}
what surprised me is that base.Render(htmlWriter) was executed twice, as long as we put RadAjaxPanel on a page, but other controls such as RadGrid, DatePicker, RadToolbar, MS UpdatePanel... work perfectly.
can anybody tell me why?
reportCataloguePanel.DataSource = dataset1;
reportCataloguePanel.DataFieldID =
"Group";
reportCataloguePanel.DataFieldParentID =
"SubGroup";
reportCataloguePanel.DataBind();
A runtime error was thrown showing "These columns don't currently have unique values."
Is there some technical explanation available for the apparent restriction upon the use of "code blocks" within pages containing the RadUpload control?
I have a VB.NET application in development using the RadUpload control. The application uses a Master Page design, with the usual Content Placeholder control to render in variable "child-page" content. One of the child-pages contains a RadUpload control.
I needed to add some client-side javascript for other child-page processes completely unrelated to the RadUpload control. That client-side javascript required the use of a .NET "code block" (<%= … %>) to render-in a value from the page's code-behind script.
The client-side javascript block is a normal script block, placed in the Master Page document HEAD. And everything about it works fine across all child-pages, until I render-in the child-page containing the RadUpload control.
At that point I get an error:
"The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>)"
A little poking around your site revealed, in a completely unrelated area, the restriction:
"The <%= .. %> codeblock must be placed inside the BODY element of the page."
http://www.telerik.com/help/aspnet-ajax/upload_clientsidebasics.html
The example noted was capturing the RadUpload control's ClientID, so I figured it didn't apply to me, since I wasn't messing with the RadUpload control at all.
And yet, just as noted, the page with the RadUpload control will not render until I place my script block (with that "code block" inside) within the Master page's BODY tag.
Now, I'm no stickler for "Script in the Head" and don't mind moving the script block. But I'd like to understand what's going on.
There are places in the final design where I will have at least one other 3rd Party control in my page, with its own clot of client-side script, collocated with the RadUpload control. And, like with the RadUpload control, I don't have a lot of influence over how that control and its scripting nestles into the rendered page.
So any explanation for the "code blocks in the body, please" requirement would be appreciated.
Thanks