Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
58 views
For some reason, we have to upgrade our project's .net framework's version from 3.5 to 4.5. But the Telerik.Web.UI.dll in our project is still 2009.3.1314.35. And the bugs happened.

All inputs width are all 100% even if you set a width to them. For example you can see the html after the RadNumberTextBox rendered.

<table cellpadding="0" cellspacing="0" class="riTable" style="border-width:0;border-collapse:collapse;width:100%;">
        <tbody><tr>
            <td class="riCell" style="width:100%;white-space:nowrap;"><input type="text" value="1" id="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount_text" name="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount_text" class="riTextBox riEnabled" style="width: 100%;" maxlength="524288"><input style="visibility:hidden;float:right;margin:-18px 0 0 -1px;width:1px;height:1px;overflow:hidden;border:0;padding:0;" id="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount" class="rdfd_" value="1" type="text"><input style="visibility:hidden;float:right;margin:-18px 0 0 -1px;width:1px;height:1px;overflow:hidden;border:0;padding:0;" id="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount_Value" class="rdfd_" name="ctl01$ContentPlaceHolder1$ProductDetail1$rptGoods$ctl00$rntbAmount" value="1" type="text"></td><td class="riSpin"><a class="riUp" href="javascript:void(0)" id="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount_SpinUpButton"><span>Spin Up</span></a><a class="riDown" href="javascript:void(0)" id="ctl01_ContentPlaceHolder1_ProductDetail1_rptGoods_ctl00_rntbAmount_SpinDownButton"><span>Spin Down</span></a></td>
        </tr>
    </tbody></table>

As you see, there are some width:100% in code, But actually, I have set a width 80px to it.

I used reflector to see the code, and found this. I guess this bug is caused by the code "this.Browser.IsBrowser("Gecko")", can you help me fix that, And build a new dll for me, because I don't have the source code,
and it is hard for us to upgrade the telerik controls to a new version. Thanks.

protected override void RenderContents(HtmlTextWriter writer)
{
    if (this.isOnlyInputRendered())
    {
        this.RenderInputElements(writer);
    }
    else
    {
        writer.AddAttribute("cellpadding", "0");
        writer.AddAttribute("cellspacing", "0");
        writer.AddStyleAttribute(HtmlTextWriterStyle.BorderWidth, "0");
        writer.AddStyleAttribute(HtmlTextWriterStyle.BorderCollapse, "collapse");
        if ((base.DesignMode || !this.Browser.IsBrowser("Gecko")) || ((this.Browser.IsBrowser("Gecko") && !this.setWidth.IsEmpty) && (this.setWidth.Type == UnitType.Percentage)))
        {
            writer.AddStyleAttribute("width", "100%");
        }
        else
        {
            writer.AddStyleAttribute("width", this.setWidth.IsEmpty ? this.defaultWidth.ToString() : this.setWidth.ToString());
        }
        writer.AddAttribute(HtmlTextWriterAttribute.Class, "riTable");
        writer.RenderBeginTag(HtmlTextWriterTag.Table);
        writer.RenderBeginTag(HtmlTextWriterTag.Tr);
        if (this.Label != "")
        {
            writer.RenderBeginTag(HtmlTextWriterTag.Td);
            this.RenderLabel(writer, this.ClientID + "_text");
            writer.RenderEndTag();
        }
        if (this.ButtonsPosition == InputButtonsPosition.Left)
        {
            base.RenderContents(writer);
        }
        writer.AddAttribute("class", "riCell");
        writer.AddStyleAttribute(HtmlTextWriterStyle.Width, "100%");
        if (!base.DesignMode && !this.Browser.IsBrowser("Safari"))
        {
            writer.AddStyleAttribute("white-space", "nowrap");
        }
        if (!base.DesignMode && this.Browser.IsBrowser("Safari"))
        {
            writer.AddStyleAttribute("white-space", "normal");
        }
        writer.RenderBeginTag(HtmlTextWriterTag.Td);
        this.RenderInputElements(writer);
        writer.RenderEndTag();
        if (this.ButtonsPosition == InputButtonsPosition.Right)
        {
            base.RenderContents(writer);
        }
        writer.RenderEndTag();
        writer.RenderEndTag();
    }
}

Vasil
Telerik team
 answered on 26 Nov 2012
3 answers
106 views
Hi,

we're using the Rad Slider in a questionnaire and it doesn't render correctly in Windows 8. I have attached 2 images showing what it looks like. One which shows what it looks like when running Metro UI or in desktop mode not using Compatibility Mode. In Metro Mode only the first slider appears in the page at all. All following sliders do not render. The other image is IE10 running Compatibility Mode which renders the slider correctly and also renders all sliders in the page.

Does anybody have a solution to this?

Thanks!

/Christofer
Slav
Telerik team
 answered on 26 Nov 2012
3 answers
158 views
Hello,

I am adding a context menu to body tag of rad editor control while "EditorContentAreaMode" is set to Div.
Problem is that, it is not showing the context menu on right click in radeditor content area..

Below is some code sample:

Setting Editor properties
Editor.EditModes = EditModes.Design | EditModes.Html;
 
            Editor.Width = new System.Web.UI.WebControls.Unit("100%", CultureInfo.InvariantCulture);
            Editor.Height = 0;
            Editor.AutoResizeHeight = true;
 
            Editor.ToolbarMode = Telerik.Web.UI.EditorToolbarMode.PageTop;
            Editor.ContentAreaMode = EditorContentAreaMode.Div;
            Editor.BackColor = System.Drawing.Color.Transparent;
            //Editor.StripFormattingOnPaste = Telerik.Web.UI.EditorStripFormattingOptions.MSWordRemoveAll;
            Editor.StripFormattingOptions = EditorStripFormattingOptions.MSWordRemoveAll;
 
            Editor.ToolsFile = "/Modules/HtmlArticle/ToolsFile.xml";
            InternalLinks EditorLinks = new InternalLinks();
            Editor = EditorLinks.LoadLinks(Editor);
            Editor = CSSClass.LoadCSSToParagraphList(Editor);
            Editor.CssClasses.Clear();
            Editor.CssFiles.Clear();
            Editor.CssFiles.Add("/mb/pub/css/default.css");
            Editor.CssClass = "mb_modules_HtmlArticle_articleEditors";

Adding context menu

   EditorTool SaveDraftTool = new EditorTool();
  SaveDraftTool.Text = "Save Draft";
  SaveDraftTool.Name = "SaveDraft";
  EditorContextMenu forBody = new EditorContextMenu();
  forBody.TagName = "BODY";
  forBody.Tools.Add(SaveDraftTool);
  Editor.ContextMenus.Add(forBody);


shadow
Top achievements
Rank 2
 answered on 26 Nov 2012
1 answer
69 views
How to hide or remove saturday and sunday checkboxes of weekly recurrence of radschedulerrecurrenceeditor?
Shinu
Top achievements
Rank 2
 answered on 26 Nov 2012
1 answer
86 views
How can i traverse through all the items in the radlistbox.
Princy
Top achievements
Rank 2
 answered on 26 Nov 2012
2 answers
40 views
hi 
i need to collapse one particular row but i'm not in the item data bound but in a onclick of a radbutton 

how could i do ?

thanks
Eyup
Telerik team
 answered on 26 Nov 2012
1 answer
99 views
Hi,

I'm looking for a way to get the resource id that i've grouped my scheduler by in javascript. Is this possible?
Using OnClientAppointmentInserting i can get the start time and is all day properties. Is there any way to get the room id that i have grouped by?

function AppointmentInserting(sender, eventArgs) {
                    var start = formatDate(eventArgs.get_startTime());
                    var isAllDay = eventArgs.get_isAllDay();
                    alert(start);
                    alert(isAllDay);
                    eventArgs.set_cancel(true);
                }
Plamen
Telerik team
 answered on 26 Nov 2012
1 answer
51 views
How can i decrease the space between the items of the radrating?
Princy
Top achievements
Rank 2
 answered on 26 Nov 2012
1 answer
106 views
I have a radrating in my form. I want to validate whether the rating is checked using a customvalidator. Please help me to achieve this scenario.
Princy
Top achievements
Rank 2
 answered on 26 Nov 2012
4 answers
91 views
The new asp.net demos are not that great.  

To start with they use the new windows style which I think looks awful but accept that is a subjective opinion.

More importantly I have the following issues:
1) They are very slow
2) The Forum link is now missing
3) The documentation link is now missing
4) The size of them is such that even on my large monitor I'm having to scroll up and down a lot.
5) Rather than reskinning the demos maybe a more relevant focus would be on expanding their quantity so that more items are covered. 

You're going down the devexpress route of redoing the website more for the look of it than for the functional use..

Jon
Iana Tsolova
Telerik team
 answered on 26 Nov 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Iron
Iron
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
Radek
Top achievements
Rank 2
Iron
Iron
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Richard
Top achievements
Rank 4
Bronze
Bronze
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?