<
Resizing AllowColumnResize="True" EnableRealTimeResize="True" ResizeGridOnColumnResize="True" />
hi,
I've a user control and the page that holds it has a Radscriptmgr.
I've the foll js fn:
<script type="text/javascript">
//js function which calls the makeUnselectable().
function OnClientLoad(combobox, args)
{
makeUnselectable(combobox.get_element());
}
//Make all combobox items unselectable to prevent selection in editor being lost
function makeUnselectable(element)
{
var nodes = element.getElementsByTagName('*');
for (var index = 0; index < nodes.length; index++) {
var elem = nodes[index];
elem.setAttribute('unselectable', 'on');
}
}
//js function which isused to get refernce of the client object
function getSelected()
{
//get a reference to Radcombobox client object
var obTagCombo = $find('<%=m_radTagCombo.ClientID %>');
//get_value() returns the value of the control
var value = obTagCombo.get_value();
//get_text()returns the text of the control.
var text = obTagCombo.get_text();
//get a reference to RadEditor client object
var editor = $find("<%=m_radEmailEditor.ClientID%>");
//pasteHtml method is used to paste the contents passed to the editor control.
editor.pasteHtml(text);
}
</script>
and i call it
<input type="button" value="Insert Tag" onclick="getSelected();" />
and in radcombobox: <telerik:RadComboBox ID="m_radTagCombo" OnClientLoad="OnClientLoad" runat="server">
</telerik:RadComboBox>
I need to select text from radcombo and click the insert btn and the selected text from radcombo gets pasted on to the radeditor.
Now, I get a "Microsoft JScript runtime error: 'OnClientLoad' is undefined"
Pls help me with code:
| <form id="form1" runat="server"> |
| <div> |
| <telerik:RadScriptManager ID="radScriptManager1" runat="server" /> |
| <telerik:RadGrid ID="radGrid1" AutoGenerateColumns="false" GridLines="Vertical" OnItemCreated="radGrid_ItemCreated" OnNeedDataSource="radGrid_NeedDataSource" OnUpdateCommand="radGrid_UpdateCommand" runat="server"> |
| <ClientSettings> |
| <Scrolling UseStaticHeaders="true" /> |
| </ClientSettings> |
| <MasterTableView EditMode="InPlace" TableLayout="Fixed"> |
| <Columns> |
| <telerik:GridBoundColumn DataField="Description" DataType="System.String" HeaderText="Description" HeaderStyle-HorizontalAlign="Left" ItemStyle-HorizontalAlign="Left" UniqueName="Description" /> |
| <telerik:GridEditCommandColumn ButtonType="LinkButton" UniqueName="Edit" /> |
| </Columns> |
| </MasterTableView> |
| </telerik:RadGrid> |
| </div> |
| </form> |
| public partial class Grid : System.Web.UI.Page |
| { |
| private ArrayList _data; |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| if (!IsPostBack) |
| { |
| this._data = Data.Load(); |
| Session["DATA"] = this._data; |
| } |
| else |
| { |
| this._data = (ArrayList)Session["DATA"]; |
| } |
| } |
| protected void radGrid_ItemCreated(object sender, GridItemEventArgs e) |
| { |
| if (e.Item is GridEditableItem && e.Item.IsInEditMode) |
| { |
| GridEditableItem item = (GridEditableItem)e.Item; |
| TextBox textbox = (TextBox)item["Description"].Controls[0]; |
| textbox.Width = Unit.Percentage(99); |
| } |
| } |
| protected void radGrid_NeedDataSource(object source, GridNeedDataSourceEventArgs e) |
| { |
| this.radGrid.DataSource = this._data; |
| } |
| protected void radGrid_UpdateCommand(object sender, GridCommandEventArgs e) |
| { |
| if (e.Item is GridEditableItem && e.Item.IsInEditMode) |
| { |
| GridEditableItem item = (GridEditableItem)e.Item; |
| ((Data)(this._data[item.ItemIndex])).Description = ((TextBox)item["Description"].Controls[0]).Text; |
| Session["DATA"] = this._data; |
| } |
| } |
| } |
| public class Data |
| { |
| public string Description { get; set; } |
| public Data(string description) |
| { |
| Description = description; |
| } |
| public static ArrayList Load() |
| { |
| ArrayList arrayList = new ArrayList(); |
| arrayList.Add(new Data("Cheeses")); |
| arrayList.Add(new Data("Prepared meats")); |
| arrayList.Add(new Data("Seaweed and fish")); |
| return arrayList; |
| } |
| } |
| <telerik:RadToolTipManager ID="RadToolTipManager1" OffsetY="-1" HideEvent="LeaveTargetAndToolTip" |
| Width="410" Height="150" runat="server" OnAjaxUpdate="OnAjaxUpdate" RelativeTo="Element" |
| Position="TopCenter"> |
| </telerik:RadToolTipManager> |
Hi.
Is there any updates on the problem described in thread “TabStrip with ScrollChildren too wide in Firefox 3”: my TabStrip is 10,000 px wide in IE 8. My Telerik DLL version is 2009.2.701.35.
The JavaScript workaround you provided in the mentioned thread does not work for me since I am generating multiple tabstrips dynamically from code behind with dynamic names and also I have tabstrips inside other tabstrips.
Thank you for any suggestions.

function HideTooltip() {
var tooltip = Telerik.Web.UI.RadToolTip.getCurrent();
if (tooltip) tooltip.hide();
}
<telerik:RadToolTip runat="server" ID="rttLnameCk" ShowCallout="false" Position="MiddleRight"
RelativeTo="Element">
<asp:CheckBoxList ID="cblLastName" runat="server" CellSpacing="0" CellPadding="0">
</asp:CheckBoxList>
<asp:Button ID="btSelect" runat="server" Text="Select" OnClientClick="InsertName(); return false;" />
</telerik:RadToolTip>
thank you for all your help