or
| <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="AjaxPanel.aspx.cs" Inherits="WebApplication10.AjaxPanel" %> |
| <!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></title> |
| </head> |
| <body> |
| <form id="form1" runat="server"> |
| <div> |
| <img src="<%= MyServer + "images/uparrow.gif"%>" /> |
| <telerik:RadScriptManager ID="mgr1" runat="server"></telerik:RadScriptManager> |
| <telerik:RadAjaxPanel ID="panel1" runat="server"></telerik:RadAjaxPanel> |
| </div> |
| </form> |
| </body> |
| </html> |
| ================================== |
| using System; |
| using System.Collections.Generic; |
| using System.Linq; |
| using System.Web; |
| using System.Web.UI; |
| using System.Web.UI.WebControls; |
| namespace WebApplication10 |
| { |
| public partial class AjaxPanel : System.Web.UI.Page |
| { |
| public string MyServer { get { return "http://server/"; } } |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| } |
| } |
| } |
| <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="AjaxPanel.aspx.cs" Inherits="WebApplication10.AjaxPanel" %> |
| <!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></title> |
| </head> |
| <body> |
| <form id="form1" runat="server"> |
| <div> |
| <img src="<%= MyServer + "images/uparrow.gif"%>" /> |
| <telerik:RadScriptManager ID="mgr1" runat="server"></telerik:RadScriptManager> |
| <div id="wrapper" runat="server"> |
| <telerik:RadAjaxPanel ID="panel1" runat="server"></telerik:RadAjaxPanel> |
| </div> |
| </div> |
| </form> |
| </body> |
| </html> |
RadEditor

| <telerik:RadEditor runat="server" SkinID="SettingProperties" ID="uxStoryHTML"> |
| </telerik:RadEditor> |
| <telerik:RadEditor runat="server" SkinID="SettingProperties" ContentFilters="MakeUrlsAbsolute" StripFormattingOptions="All"> |
| <DocumentManager SearchPatterns="*.doc,*.docx,*.pdf,*.xls,*.xlsx" DeletePaths="~/uploads/docs/" UploadPaths="~/uploads/docs/" ViewPaths="~/uploads/docs/" MaxUploadFileSize="10240000" /> |
| <ImageManager ImageEditorFileSuffix="*.gif,*.jpg,*.jpeg,*.png,*.bmp" DeletePaths="~/uploads/images/" UploadPaths="~/uploads/images/" ViewPaths="~/uploads/images/" MaxUploadFileSize="604800" /> |
| <MediaManager SearchPatterns="*.avi,*.mpeg,*.mp3,*.wma,*.wav,*.wmv,*.mpg,*.mov" DeletePaths="~/uploads/videos/" UploadPaths="~/uploads/videos/" ViewPaths="~/uploads/videos/" MaxUploadFileSize="5242880" /> |
| <FlashManager SearchPatterns="*.flv,*.swf" DeletePaths="~/uploads/flash/" UploadPaths="~/uploads/flash/" ViewPaths="~/uploads/flash/" MaxUploadFileSize="1024000"/> |
| <TemplateManager SearchPatterns="*.htm,*.html" /> |
| <CssFiles> |
| <telerik:EditorCssFile Value="~/CSS/cms.css" /> |
| </CssFiles> |
| <Tools> |
| <telerik:EditorToolGroup> |
| <telerik:EditorTool Name="AjaxSpellCheck" /> |
| <telerik:EditorTool Name="FindAndReplace" /> |
| <telerik:EditorTool Name="Copy" /> |
| <telerik:EditorTool Name="Paste" /> |
| <telerik:EditorTool Name="PasteFromWord" /> |
| <telerik:EditorTool Name="PasteFromWordNoFontsNoSizes" /> |
| <telerik:EditorTool Name="PastePlainText" /> |
| <telerik:EditorTool Name="PasteAsHtml" /> |
| <telerik:EditorTool Name="Undo" /> |
| <telerik:EditorTool Name="Redo" /> |
| <telerik:EditorSeparator Visible="true" /> |
| <telerik:EditorTool Name="ImageManager" /> |
| <telerik:EditorTool Name="DocumentManager" /> |
| <telerik:EditorTool Name="LinkManager" /> |
| <telerik:EditorTool Name="Unlink" /> |
| </telerik:EditorToolGroup> |
| <telerik:EditorToolGroup> |
| <telerik:EditorTool Name="JustifyLeft" /> |
| <telerik:EditorTool Name="JustifyCenter" /> |
| <telerik:EditorTool Name="JustifyRight" /> |
| <telerik:EditorTool Name="JustifyFull" /> |
| <telerik:EditorTool Name="JustifyNone" /> |
| <telerik:EditorSeparator Visible="true" /> |
| <telerik:EditorTool Name="Indent" /> |
| <telerik:EditorTool Name="Outdent" /> |
| <telerik:EditorTool Name="InsertOrderedList" /> |
| <telerik:EditorTool Name="InsertUnorderedList" /> |
| <telerik:EditorSeparator Visible="true" /> |
| <telerik:EditorTool Name="ConvertToLower" /> |
| <telerik:EditorTool Name="ConvertToUpper" /> |
| <telerik:EditorSeparator Visible="true" /> |
| <telerik:EditorTool Name="InsertTable" /> |
| <telerik:EditorTool Name="InsertSymbol" /> |
| </telerik:EditorToolGroup> |
| <telerik:EditorToolGroup> |
| <telerik:EditorTool Name="FormatStripper" /> |
| <telerik:EditorTool Name="FormatBlock" /> |
| <telerik:EditorTool Name="ApplyClass" /> |
| <telerik:EditorTool Name="Print" /> |
| <telerik:EditorTool Name="Superscript" /> |
| <telerik:EditorTool Name="Subscript" /> |
| <telerik:EditorTool Name="InsertParagraph" /> |
| <telerik:EditorTool Name="InsertHorizontalRule" /> |
| <telerik:EditorTool Name="InsertDate" /> |
| <telerik:EditorTool Name="InsertTime" /> |
| <telerik:EditorTool Name="AboutDialog" /> |
| <telerik:EditorTool Name="Help" /> |
| </telerik:EditorToolGroup> |
| </Tools> |
| <Modules> |
| <telerik:EditorModule Name="RadEditorStatistics" /> |
| <telerik:EditorModule Name="RadEditorDomInspector" /> |
| <telerik:EditorModule Name="RadEditorNodeInspector" /> |
| </Modules> |
| </telerik:RadEditor> |
| <InlineInsertTemplate> |
| <div id="InlineInsertTemplate"> |
| <table> |
| [... Other code with date and event's description ...] |
| <tr id="quid"> |
| <td> |
| <asp:Label ID="lbl_quid_advanced_insertion" runat="server" Text="Civ, Nom, Prénom : "></asp:Label> |
| </td> |
| <td style="width:auto;"> |
| <asp:DropDownList ID="ddl_civilite" runat="server"> |
| <asp:ListItem>Mlle</asp:ListItem> |
| <asp:ListItem>Madame</asp:ListItem> |
| <asp:ListItem>Monsieur</asp:ListItem> |
| </asp:DropDownList> |
| </td> |
| <td> |
| <asp:TextBox ID="TxtNomComplet" runat="server"></asp:TextBox> |
| </td> |
| </tr> |
| <tr id="identifiant"> |
| <td> |
| <asp:Label ID="lbl_identifiant_advanced_insertion" runat="server" Text="Identifiant (ex : Carte de fidélité) : "></asp:Label> |
| </td> |
| <td> |
| <asp:TextBox ID="txt_identifiant_advanced_insertion" runat="server"></asp:TextBox> |
| </td> |
| </tr> |
| <tr id="tel1"> |
| <td> |
| <asp:Label ID="lbl_tel1_advanced_insertion" runat="server" Text="Tel 1 : "></asp:Label> |
| </td> |
| <td> |
| <asp:TextBox ID="txt_tel1_advanced_insertion" runat="server"></asp:TextBox> |
| </td> |
| </tr> |
| <tr id="tel2"> |
| <td> |
| <asp:Label ID="lbl_tel2_advanced_insertion" runat="server" Text="Tel 2 : "></asp:Label> |
| </td> |
| <td> |
| <asp:TextBox ID="txt_tel2_advanced_insertion" runat="server"></asp:TextBox> |
| </td> |
| </tr> |
| </table> |
| </div> |
| </InlineInsertTemplate> |
| OnAppointmentInsert="RadScheduler1_AppointmentInsert" |
| OnAppointmentUpdate="RadScheduler1_AppointmentUpdate" |
| protected void RadScheduler1_AppointmentInsert(object sender, SchedulerCancelEventArgs e) |
| { |
| Event monevenement = new Event(); |
| Event.InsertEvent(1, "testinsertnom", DateTime.Now, DateTime.Now, "testinsertmotif", TxtNomComplet ... others variables); |
| } |
| function showToolTip(element) { |
| var tooltipManager = $find("<%= RadToolTipManager1.ClientID %>"); |
| if (!tooltipManager) return; |
| var tooltip = tooltipManager.getToolTipByElement(element); |
| if (!tooltip) { |
| tooltip = tooltipManager.createToolTip(element); |
| var partNo = element.innerHTML; |
| tooltip.set_value(partNo); |
| } |
| element.onmouseover = null; |
| try { |
| tooltip.show(); |
| } |
| catch(ex) { |
| alert(ex.description); |
| } |
| } |
| <telerik:RadToolTipManager ID="RadToolTipManager1" runat="server" |
| AutoCloseDelay="10000" Width="160px" Height="70px" |
| RelativeTo="Element" |
| Position="MiddleRight" Skin="Outlook"> |
| <WebServiceSettings Path="GetPartToolTip.asmx" Method="GetPartInfo" /> |
| <TargetControls> |
| <telerik:ToolTipTargetControl IsClientID="false" TargetControlID="txtFakeTooltip" Value="" /> |
| </TargetControls> |
| </telerik:RadToolTipManager> |
| Imports System.Web |
| Imports System.Web.Services |
| Imports System.Web.Services.Protocols |
| Imports System.ComponentModel |
| Imports System.Web.UI |
| Imports System.Web.UI.WebControls |
| Imports System.Reflection |
| Imports System.IO |
| Imports System.Collections |
| ' To allow this Web Service to be called from script, using ASP.NET AJAX, uncomment the following line. |
| ' <System.Web.Script.Services.ScriptService()> _ |
| <WebService(Namespace:="http://tempuri.org/")> _ |
| <WebServiceBinding(ConformsTo:=WsiProfiles.BasicProfile1_1)> _ |
| <Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _ |
| Public Class GetPartToolTip |
| Inherits System.Web.Services.WebService |
| <WebMethod()> _ |
| Public Function GetPartInfo(ByVal context As String) As String |
| Try |
| 'Return "Hello" |
| 'Dim contextDictionary As IDictionary(Of String, Object) = CType(context, IDictionary(Of String, Object)) |
| 'Dim elementID As String = CType(contextDictionary("Value"), String) |
| If String.IsNullOrEmpty(context) Then |
| Throw New Exception("No Value argument is provided to the webservice!") |
| End If |
| Return ViewManager.RenderView("part_availability.ascx", context) |
| Catch ex As Exception |
| Return "Error occurred in GetPartInfo. Error: " & ex.Message |
| End Try |
| End Function |
| End Class |
| Public Class ViewManager |
| Public Shared Function RenderView(ByVal path As String, ByVal partno As String) As String |
| Dim pageHolder As Page = New Page |
| Dim viewControl As UserControl = CType(pageHolder.LoadControl(path), UserControl) |
| Dim viewControlType As Type = viewControl.GetType |
| Dim partNbr As FieldInfo = viewControlType.GetField("partno") |
| If Not partNbr Is Nothing Then |
| partNbr.SetValue(viewControl, partno) |
| Else |
| Throw New Exception("View file: " & path & " does not have a public 'partno' property") |
| End If |
| pageHolder.Controls.Add(viewControl) |
| Dim output As StringWriter = New StringWriter |
| HttpContext.Current.Server.Execute(pageHolder, output, False) |
| Return output.ToString |
| End Function |
| End Class |