Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
236 views
Hello forum

I'm fairly sure that I am suffering from a well-known Firefox bug concerning the disappearance of the 'caret' text-cursor from within the radEditor content area. My particular scenario, which from my research I gather is not unusual, is that I have the radEditor inside a hidden DIV when the page first loads, after which the radEditor can eventually be displayed by the user's actions, through client-side/CSS manipulation of the container DIV which is then set to be visible. After this occurs though, the caret stubbornly refuses to appear inside the content area Iframe, through any workaround I have yet to try. Of course if the user minimises and maximises the window again, instantly the caret returns, blinking away as if nothing had gone wrong!

Most of the workarounds cited seem to be based around either re-setting the "contenteditable" or "designMode" attributes for various components of the radEditor, the Iframe, the DIV etc., or manipulation of visibility and textflow CSS properties. Unfortunately nothing I have yet to try makes the slightest bit of difference - so after many hours wasted, I thought it was best to come to the forum to ask if there is any prevailing view on the best way to approach this problem, for example, "contenteditable", CSS, or some other approach?

If anybody can shed light on the current thinking for solving this long-standing annoyance, I would really be grateful for a pointer in the right direction.

Regards

 
Paul Robertson
Top achievements
Rank 1
 answered on 28 May 2012
1 answer
119 views
Hi there,

we have recently implemented the drag-drop feature within the Telerik RadGrid using the demo provided by yourselves: 
http://demos.telerik.com/aspnet-ajax/grid/examples/programming/draganddrop/defaultcs.aspx 

This is working beautifully however we have had a request to disable the drag-drop feature on 1 or 2 'unsortable' rows, could you please provide some indication on how to acheive this? we have attempted casting the object, on ItemDataBound, to a Telerik.Web.UI.GridDataItem and then setting enable=false but this doesnt seem to be working.

Hope you can be of assistance

Regards

A.
Jayesh Goyani
Top achievements
Rank 2
 answered on 28 May 2012
4 answers
137 views
Hello Guys

i need to mark up selected items of my slider in bold.
But i need to do it in range. (pls check attachament for example)

When user sliding left handle from "a" to "b" 
items b,c,d,e,f have to be display bold.

any help?

Regards

 
slider 

a   b    c    d    e    f
omer
Top achievements
Rank 1
 answered on 28 May 2012
1 answer
119 views
Hi All,

I am facing issue while customizing RadScedular. The event for Edit Appointment/Delete Appointment / Dragging appointment on to different date cell are not firing by the customization I have used so far. Only the thing I can do is to insert new appointment.

I am sending code & markup of my page:-

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" %>

<%@ 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>Untitled Page</title>
    <link rel="stylesheet" href="App_Themes/Default/schedular.css" type="text/css" />
    <link rel="stylesheet" href="App_Themes/Default/CustomStyles.css" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <div>
    
    </div>
    <telerik:RadScriptManager ID="RadScriptManager1" Runat="server">
        <Scripts>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js"></asp:ScriptReference>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js"></asp:ScriptReference>
<asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js"></asp:ScriptReference>
</Scripts>
    </telerik:RadScriptManager>
    <telerik:RadScheduler ID="radDoctorsScheduler" runat="server" DataDescriptionField="Subject"
        DataEndField="End" DataKeyField="AppointmentID" DataRecurrenceField="RecurrenceRule"
        DataRecurrenceParentKeyField="RecurrenceParentID" DataStartField="Start" DataSubjectField="Subject"
        EnableDescriptionField="True" DayStartTime="08:00:00" DayEndTime="18:00:00" ShowsConfirmationWindowOnDelete="False"
        OnAppointmentInsert="radDoctorsScheduler_AppointmentInsert" OnAppointmentDelete="radDoctorsScheduler_AppointmentDelete" AllowDelete="true" AllowEdit="true" DisplayDeleteConfirmation="false"
        OnAppointmentUpdate="radDoctorsScheduler_AppointmentUpdate" OnAppointmentCommand="radDoctorsScheduler_AppointmentCommand">
      
        
        <InlineInsertTemplate>
            <div id="InlineInsertTemplate" class="rsCustomAppointmentContainer technical">
                <div>
                </div>
                <span class="rsCustomAppointmentContainerInner">
                    <table style="width:100%;border:0px:height:150px" cellpadding="0" cellspacing="0">
                        <tr>
                            <td style="width:25%">
                                 Subject:
                            </td>
                            <td style="width: 75%">
                                <asp:TextBox ID="TitleTextBox" runat="server" Text='<%# Bind("Subject") %>' Width="90%"
                                    TextMode="MultiLine" Height="20px"></asp:TextBox>   
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                                Doctor:
                            </td>
                            <td style="width: 75%">
                                <telerik:RadComboBox ID="ddlDoctors" runat="server" AutoPostBack="true" OnSelectedIndexChanged="ddlDoctors_SelectedIndexChanged"
                                    DataValueField="DoctorID" DataTextField="DoctorName" CssClass="AppointmentTypeSelectorTable"
                                    DataSourceID="DoctorsDS">                            
                                </telerik:RadComboBox>                             
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                                
                            </td>
                            <td>
                                <asp:LinkButton ID="InsertMoreButton" runat="server" CommandName="More" CssClass="rsAdvancedEditLink">Advanced</asp:LinkButton>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                            </td>
                            <td>
                                <asp:LinkButton ID="InsertButton"  runat="server"
                                    CommandName="Insert"  >
                                    <asp:Image runat="server" ID="insertImage" ImageUrl="~/App_Themes/Default/Images/ok.png"
                                        AlternateText="insert" />
                                </asp:LinkButton>
                                <asp:LinkButton ID="InsertCancelButton" runat="server" CausesValidation="False" CommandName="Cancel">
                                    <asp:Image runat="server" ID="imgCancel" ImageUrl="~/App_Themes/Default/Images/cancel.png"
                                        AlternateText="cancel" />
                                </asp:LinkButton>
                            </td>
                        </tr>
                    </table>
                </span>
            </div>
        </InlineInsertTemplate>
        
        <InlineEditTemplate>
            <div id="InlineEditTemplate" class="rsCustomAppointmentContainer technical">
                <div>
                </div>
                <span class="rsCustomAppointmentContainerInner">
                    <table style="width: 100%; border: 0px:height:150px" cellpadding="0" cellspacing="0">
                        <tr>
                            <td style="width: 25%">
                                Subject:
                            </td>
                            <td style="width: 75%">
                                <asp:TextBox ID="TitleTextBox" runat="server" Text='<%# Bind("Subject") %>' Width="90%"
                                    TextMode="MultiLine" Height="20px"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                                Doctor:
                            </td>
                            <td style="width: 75%">
                                <telerik:RadComboBox ID="ddlDoctors" runat="server" AutoPostBack="true" OnSelectedIndexChanged="ddlDoctors_SelectedIndexChanged"
                                    DataValueField="DoctorID" DataTextField="DoctorName" CssClass="AppointmentTypeSelectorTable"
                                    DataSourceID="DoctorsDS">
                                </telerik:RadComboBox>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                            </td>
                            <td>
                                <asp:LinkButton ID="InsertMoreButton" runat="server" CommandName="More" CssClass="rsAdvancedEditLink">Advanced</asp:LinkButton>
                            </td>
                        </tr>
                        <tr>
                            <td style="width: 25%">
                            </td>
                            <td>
                                <asp:LinkButton ID="InsertButton" runat="server" CommandName="Insert">
                                    <asp:Image runat="server" ID="insertImage" ImageUrl="~/App_Themes/Default/Images/ok.png"
                                        AlternateText="insert" />
                                </asp:LinkButton>
                                <asp:LinkButton ID="InsertCancelButton" runat="server" CausesValidation="False" CommandName="Cancel">
                                    <asp:Image runat="server" ID="imgCancel" ImageUrl="~/App_Themes/Default/Images/cancel.png"
                                        AlternateText="cancel" />
                                </asp:LinkButton>
                            </td>
                        </tr>
                    </table>
                </span>
            </div>
        </InlineEditTemplate>
        
    </telerik:RadScheduler>
    <asp:SqlDataSource ID="IDSAppointments" runat="server" ConnectionString="<%$ ConnectionStrings:SchedularDBConnectionString %>"
        InsertCommand="[spInsertUpdateAppointment] null,@DoctorID,@Start, @End, @Subject, @RecurrenceRule, @RecurrenceParentID"
        UpdateCommand="[spInsertUpdateAppointment] @AppointmentID,@DoctorID,@Start,@End,@Subject,@RecurrenceRule,@RecurrenceParentID"
        DeleteCommand="[spDeleteAppointment] @AppointmentID" SelectCommand="[spGetAllAppointments]">
        <DeleteParameters>
            <asp:Parameter Name="AppointmentID" Type="Int32" />
        </DeleteParameters>
        <UpdateParameters>
            <asp:Parameter DbType="Date" Name="Start" />
            <asp:Parameter DbType="Date" Name="End" />
            <asp:Parameter Name="Subject" Type="String" />
            <asp:Parameter Name="RecurrenceRule" Type="String" />
            <asp:Parameter Name="RecurrenceParentID" Type="Int32" />
            <asp:Parameter Name="AppointmentID" Type="Int32" />
        </UpdateParameters>
        <InsertParameters>
            <asp:Parameter DbType="Date" Name="Start" />
            <asp:Parameter DbType="Date" Name="End" />
            <asp:Parameter Name="Subject" Type="String" />
            <asp:Parameter Name="RecurrenceRule" Type="String" />
            <asp:Parameter Name="RecurrenceParentID" Type="Int32" />
        </InsertParameters>
    </asp:SqlDataSource>
    
    <asp:SqlDataSource ID="DoctorsDS" runat="server" ProviderName="System.Data.SqlClient"
        ConnectionString="<%$ ConnectionStrings:SchedularDBConnectionString %>" SelectCommand="SELECT * FROM [Doctors]">
    </asp:SqlDataSource>
    
    <asp:HiddenField runat="server" ID="hdnDoctorID" />
    
    
    </form>
</body>
</html>

//////////////////////////////////////////////////////////////////////////////
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;
using System.ComponentModel;
using Telerik.Web.UI;

public partial class Default2 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void radDoctorsScheduler_AppointmentInsert(object sender, Telerik.Web.UI.AppointmentInsertEventArgs e)
    {
        Appointment apt = e.Appointment;
        DAL.InsertUpdateAppointment(0, Convert.ToInt32(hdnDoctorID.Value), apt.Start, apt.End, apt.Subject, apt.RecurrenceRule, Convert.ToInt32(apt.RecurrenceParentID));
    }
    protected void ddlDoctors_SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
    {
        RadComboBox ddlDoctors = (RadComboBox)sender;
        hdnDoctorID.Value = ddlDoctors.SelectedValue;
    }
    protected void radDoctorsScheduler_AppointmentUpdate(object sender, AppointmentUpdateEventArgs e)
    {
        Appointment apt = e.Appointment;
        DAL.InsertUpdateAppointment(Convert.ToInt32(apt.ID), Convert.ToInt32(hdnDoctorID.Value), apt.Start, apt.End, apt.Subject, apt.RecurrenceRule, Convert.ToInt32(apt.RecurrenceParentID));
    }
    protected void radDoctorsScheduler_AppointmentDelete(object sender, AppointmentDeleteEventArgs e)
    {
        Appointment apt = e.Appointment;
        DAL.DeleteAppointment(Convert.ToInt32(apt.ID));


        radDoctorsScheduler.DeleteAppointment(e.Appointment, true);


        //radDoctorsScheduler.Appointments[0].Re.Remove(e.Appointment.ID);  
    }
    protected void radDoctorsScheduler_AppointmentCommand(object sender, AppointmentCommandEventArgs e)
    {

    }
}

Please suggest why events of schedular are not firing up?

Ivana
Telerik team
 answered on 28 May 2012
1 answer
142 views
I am building a small photo gallery where individual items can have a caption associated with them and changing this value is completed with a simple radprompt() call. The problem I have run into is since user's could enter characters that would break javascript (such as apostrophe's) I do an HtmlEncode on the original value which is filled into the prompt box as the default value. When the prompt displays though, the HtmlEncoded characters (such as &#39 for an apostrophe) are shown in the prompt box which is obviously not ideal. Is there a way to get the correct characters to show for the default value?
Marin Bratanov
Telerik team
 answered on 28 May 2012
1 answer
165 views

Team,

I am using telerik combobox containing check box in it.

(referred URL: http://demos.telerik.com/aspnet-ajax/combobox/examples/functionality/checkboxes/defaultcs.aspx )

I have a following requirement in my application

1.Change “Check All” label to “Select All”

2.I want to check if all items are checked using “Check All” option on client side because I have notice that  OnClientItemChecked

Event Is not get triggered when all items are checked using  “Check All” option  is there alternate way for this?  

3. Whenever I select items using checkbox all checked item get displayed in combo text with comma separator but the time when focus lost from the combobox only first selected item get display in combo text. It is working proper in a demo. Can you please let me know what can be the cause of this behavior?

Thanks in advance                         

Princy
Top achievements
Rank 2
 answered on 28 May 2012
1 answer
68 views
I have a treeview within a RadPan which is inside a radSplitter which is inside a MasterPage. The nodes are dynamically created and the NavigateUrl looks like this :
cn.NavigateUrl = "Secure/" & row("NavigateURL").ToString() 

The HTML source for a particular node looks like this:
href="Secure/TaskManager.aspx"

On the click of the node I get the following error.

The 'href' property had a malformed URL: Cannot use a leading .. to exit above the top directory..

What could be the problem?
Plamen
Telerik team
 answered on 28 May 2012
3 answers
156 views
Customer is requesting the "Remove Link" toolbar button be disabled/unavailable until the cursor is moved onto a link in the editor content. Is this possible to do?

Thanks.
Rumen
Telerik team
 answered on 28 May 2012
2 answers
425 views
I have to set the value of a RadNumerictextBox. The first problem is that it is in a repeater so I cannot get the object by id. And the second problem is, the event is not fired by the NumericTextBox, but by another control in the repeater (in the same line), so I cannot use the sender argument of the function.

I am able to get the parent of the first control (the one that fires the event), and then look through its children and find the many html elements the RadNumerictextBox renders to. But these are html elements and don't expose the client api.

Specifically it renders into a span containing a span and an input. I had assumed that the first span represents the value displayed, and the input the actual value, the one sent back to the server.
I tried to cheat and access these two elements through their classes and set their values, but it doesn't work. The new value shows up for a second and then resets.

tldr: I need a way to access the NumericTextBox and set its value, in a javascript event fired by another control in the same line in a repeater.

If I had not explained my problem clearly enough please say so and I shall attempt to provide you with more details.
Luka
Top achievements
Rank 1
 answered on 28 May 2012
0 answers
162 views
Hello All,

I have a typical problem.I have a grid in one of my panel bar. I am using normal asp grid view. I am getting all the count values and I am binding the data to the grid also by finding the grid

  Sample: GridView grdPropertyType = (GridView)RadPanelBar1.FindItemByValue("propertyType").FindControl("grdPropertyType");
          
grdPropertyType .DataSource=data;(I have count of 10 values)
grdPropertyType.DataBind();

---------------
and I am using the following code to bind the data:


 protected void grdPropertyType_DataBound(object sender,GridViewRowEventArgs e)
        {
            if (e.Row.RowType == DataControlRowType.DataRow)
            {
                
                Label lblPropertyTypeName = (Label)e.Row.FindControl("lblPropertyTypeData");
                Label lblPropertyTypeCount = (Label)e.Row.FindControl("lblPropertyTypeCountData");
                PropertyListView rowData = (PropertyListView)e.Row.DataItem;
 
                lblPropertyTypeName.Text = rowData.PropertyTypeDesc;
                lblPropertyTypeCount.Text = rowData.PropertyTypeCount.ToString();
 
            }
 
        }

-----------------------Is my code wrong?

My problem is,I am unable to see grid view in the rad panel bar.Can you people help me on that????

Thanks and Regards

Rama.M
 
Rama
Top achievements
Rank 1
 asked on 28 May 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?