Telerik Forums
UI for ASP.NET AJAX Forum
0 answers
62 views
Hi!

I have two user controls on page. When I click on Radtreeview in first control I want in another user control dynamically load controls


How can I do it with RadAjaxPanel or RadAjaxManager?


N
Top achievements
Rank 1
 asked on 17 Jan 2012
4 answers
280 views
Hello All,

I am using radAjaxManager with two buttons that are adjacent to each other, it seems that Ajax manager wraps the first button with a panel with display:block, this is causing the first button to display over the second button.

not sure why the display:block is used, but if it has to be used, is there a way to work around this?!!!

attached is the code and an image, and a snap of the generated code.

ASPX Code:
<div class="DialogButtons">
    <MyC:MyButton ID="btnDeleteYes" runat="server" Text="Yes"       CausesValidation="false" ></MyC:MyButton
    <MyC:MyButton ID="btnCancel" runat="server" Text="No"           CausesValidation="false" ></MyC:MyButton>                                                      
</div>
 
<telerik:RadAjaxManagerProxy ID="RadAjaxManagerProxy1" runat="server">
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="btnDeleteYes">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="btnDeleteYes" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManagerProxy>
MyButton is a custom control to wrap the button in a DIV for theming and for using a display:inline-block in order to enable divs to be adjacent. DialogButtons is a class to center the buttons in the middle of the dialog.

 

Generated HTML:
<DIV class=DialogButtons><DIV style="DISPLAY: block" id=ctl00_ContentCPH_ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1_ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1uDel_btnDeleteYesPanel>
<DIV class="MyDivButton MyDivButtonTheme">
<DIV class="MyDivButtonCorner MyDivButtonTL MyDivButtonTLTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonBL MyDivButtonBLTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonTR MyDivButtonTRTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonBR MyDivButtonBRTheme"></DIV><INPUT style="BORDER-BOTTOM-STYLE: none; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: transparent; BORDER-TOP-STYLE: none; BORDER-LEFT-STYLE: none" id=ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1_ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1uDel_btnDeleteYes class="YCIButtonSize0 YCIButton" onclick="javascript:HideToolTip('ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1_ttt');" value=Yes type=submit name=ctl00$ContentCPH$rgInbox$ctl00$ctl02$ctl00$InboxActions1$ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1uDel$btnDeleteYes> </DIV></DIV
<DIV class="MyDivButton MyDivButtonTheme">
<DIV class="MyDivButtonCorner MyDivButtonTL YCIDivButtonTLTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonBL MyDivButtonBLTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonTR MyDivButtonTRTheme"></DIV>
<DIV class="MyDivButtonCorner MyDivButtonBR MyDivButtonBRTheme"></DIV><INPUT style="BORDER-BOTTOM-STYLE: none; BORDER-RIGHT-STYLE: none; BACKGROUND-COLOR: transparent; BORDER-TOP-STYLE: none; BORDER-LEFT-STYLE: none" id=ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1_ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1uDel_btnCancel class="MyButtonSize0 MyButton" onclick="javascript:HideToolTip('ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1_ttt');return false;" value=No type=submit name=ctl00$ContentCPH$rgInbox$ctl00$ctl02$ctl00$InboxActions1$ctl00_ContentCPH_rgInbox_ctl00_ctl02_ctl00_InboxActions1uDel$btnCancel> </DIV></DIV>
Adrian
Top achievements
Rank 1
 answered on 17 Jan 2012
6 answers
115 views
I have two problems that I noticed with the new download of radControls for ASP.NET AJAX ver 2011.3 1115.

First I have had to go back to ver 2011.2 915 due to the problems below which work fine in 2011.2 915 and making the only change by updating to ver 2011.3 1115 causes the problems below.

1. I have the radTextBox control button showing and when I click on the button then nothing happens. Again in ver 2011.2.915 clicking on the button the code behind is run and works ok but with ver 2011.3.115 clicking on the button does nothing and does not run the code behind.
2. The size of the radTextBox control changes by growing in width. I have attached two images of the controls showing the size difference but only when the button is shown as the first 3 controls are also radTextBox controls and their widths stay the same.
Jerry Jansen
Top achievements
Rank 1
 answered on 17 Jan 2012
1 answer
41 views
Bonjour,
Je viens d'installer Télérik , mais cela fait des conflis avec Coolite.
Voici l'erreur qui se produit sous Internet Explorer et pas sous les autres navigateurs.
c'est coolite qui génère cette erreur.
Ext.fly(A).removeClass(["x-hidden","x-hide-display"]) a la valeur Null ou n'est pas un objet.
et avec l'espion c'est la ligne 76 
this.body.dom.appendChild(A)  BODY est indéfini 
body 'body' est indéfini.
Erreur
Ext.fly(A).removeClass(["x-hidden","x-hide-display"])
'Ext.fly(...)' a la valeur Null ou n'est pas un objet.
Erreur
dom 'dom' est indéfini.
Erreur
removeClass 'removeClass' est indéfini.
Erreur
dom 'dom' est indéfini.
Erreur
voici toute la ligne
[code]
Ext.Panel=Ext.extend(Ext.Container,{baseCls:"x-panel",collapsedCls:"x-panel-collapsed",maskDisabled:true,animCollapse:Ext.enableFx,headerAsText:true,buttonAlign:"right",collapsed:false,collapseFirst:true,minButtonWidth:75,elements:"body",toolTarget:"header",collapseEl:"bwrap",slideAnchor:"t",deferHeight:true,expandDefaults:{duration:0.25},collapseDefaults:{duration:0.25},initComponent:function(){Ext.Panel.superclass.initComponent.call(this);this.addEvents("bodyresize","titlechange","collapse","expand","beforecollapse","beforeexpand","beforeclose","close","activate","deactivate");if(this.tbar){this.elements+=",tbar";if(typeof this.tbar=="object"){this.topToolbar=this.tbar}delete this.tbar}if(this.bbar){this.elements+=",bbar";if(typeof this.bbar=="object"){this.bottomToolbar=this.bbar}delete this.bbar}if(this.header===true){this.elements+=",header";delete this.header}else{if(this.title&&this.header!==false){this.elements+=",header"}}if(this.footer===true){this.elements+=",footer";delete this.footer}if(this.buttons){var C=this.buttons;this.buttons=[];for(var B=0,A=C.length;B<A;B++){if(C[B].render){this.buttons.push(C[B])}else{this.addButton(C[B])}}}if(this.autoLoad){this.on("render",this.doAutoLoad,this,{delay:10})}},createElement:function(A,C){if(this[A]){C.appendChild(this[A].dom);return }if(A==="bwrap"||this.elements.indexOf(A)!=-1){if(this[A+"Cfg"]){this[A]=Ext.fly(C).createChild(this[A+"Cfg"])}else{var B=document.createElement("div");B.className=this[A+"Cls"];this[A]=Ext.get(C.appendChild(B))}}},onRender:function(H,G){Ext.Panel.superclass.onRender.call(this,H,G);this.createClasses();if(this.el){this.el.addClass(this.baseCls);this.header=this.el.down("."+this.headerCls);this.bwrap=this.el.down("."+this.bwrapCls);var M=this.bwrap?this.bwrap:this.el;this.tbar=M.down("."+this.tbarCls);this.body=M.down("."+this.bodyCls);this.bbar=M.down("."+this.bbarCls);this.footer=M.down("."+this.footerCls);this.fromMarkup=true}else{this.el=H.createChild({id:this.id,cls:this.baseCls},G)}var A=this.el,K=A.dom;if(this.cls){this.el.addClass(this.cls)}if(this.buttons){this.elements+=",footer"}if(this.frame){A.insertHtml("afterBegin",String.format(Ext.Element.boxMarkup,this.baseCls));this.createElement("header",K.firstChild.firstChild.firstChild);this.createElement("bwrap",K);var O=this.bwrap.dom;var E=K.childNodes[1],B=K.childNodes[2];O.appendChild(E);O.appendChild(B);var P=O.firstChild.firstChild.firstChild;this.createElement("tbar",P);this.createElement("body",P);this.createElement("bbar",P);this.createElement("footer",O.lastChild.firstChild.firstChild);if(!this.footer){this.bwrap.dom.lastChild.className+=" x-panel-nofooter"}}else{this.createElement("header",K);this.createElement("bwrap",K);var O=this.bwrap.dom;this.createElement("tbar",O);this.createElement("body",O);this.createElement("bbar",O);this.createElement("footer",O);if(!this.header){this.body.addClass(this.bodyCls+"-noheader");if(this.tbar){this.tbar.addClass(this.tbarCls+"-noheader")}}}if(this.border===false){this.el.addClass(this.baseCls+"-noborder");this.body.addClass(this.bodyCls+"-noborder");if(this.header){this.header.addClass(this.headerCls+"-noborder")}if(this.footer){this.footer.addClass(this.footerCls+"-noborder")}if(this.tbar){this.tbar.addClass(this.tbarCls+"-noborder")}if(this.bbar){this.bbar.addClass(this.bbarCls+"-noborder")}}if(this.bodyBorder===false){this.body.addClass(this.bodyCls+"-noborder")}if(this.bodyStyle){this.body.applyStyles(this.bodyStyle)}this.bwrap.enableDisplayMode("block");if(this.header){this.header.unselectable();if(this.headerAsText){this.header.dom.innerHTML="<span class=\""+this.headerTextCls+"\">"+this.header.dom.innerHTML+"</span>";if(this.iconCls){this.setIconClass(this.iconCls)}}}if(this.floating){this.makeFloating(this.floating)}if(this.collapsible){this.tools=this.tools?this.tools.slice(0):[];if(!this.hideCollapseTool){this.tools[this.collapseFirst?"unshift":"push"]({id:"toggle",handler:this.toggleCollapse,scope:this})}if(this.titleCollapse&&this.header){this.header.on("click",this.toggleCollapse,this);this.header.setStyle("cursor","pointer")}}if(this.tools){var J=this.tools;this.tools={};this.addTool.apply(this,J)}else{this.tools={}}if(this.buttons&&this.buttons.length>0){var D=this.footer.createChild({cls:"x-panel-btns-ct",cn:{cls:"x-panel-btns x-panel-btns-"+this.buttonAlign,html:"<table cellspacing=\"0\"><tbody><tr></tr></tbody></table><div class=\"x-clear\"></div>"}},null,true);var L=D.getElementsByTagName("tr")[0];for(var F=0,I=this.buttons.length;F<I;F++){var N=this.buttons[F];var C=document.createElement("td");C.className="x-panel-btn-td";N.render(L.appendChild(C))}}if(this.tbar&&this.topToolbar){if(Ext.isArray(this.topToolbar)){this.topToolbar=new Ext.Toolbar(this.topToolbar)}this.topToolbar.render(this.tbar);this.topToolbar.ownerCt=this}if(this.bbar&&this.bottomToolbar){if(Ext.isArray(this.bottomToolbar)){this.bottomToolbar=new Ext.Toolbar(this.bottomToolbar)}this.bottomToolbar.render(this.bbar);this.bottomToolbar.ownerCt=this}},setIconClass:function(B){var A=this.iconCls;this.iconCls=B;if(this.rendered&&this.header){if(this.frame){this.header.addClass("x-panel-icon");this.header.replaceClass(A,this.iconCls)}else{var D=this.header.dom;var C=D.firstChild&&String(D.firstChild.tagName).toLowerCase()=="img"?D.firstChild:null;if(C){Ext.fly(C).replaceClass(A,this.iconCls)}else{Ext.DomHelper.insertBefore(D.firstChild,{tag:"img",src:Ext.BLANK_IMAGE_URL,cls:"x-panel-inline-icon "+this.iconCls})}}}},makeFloating:function(A){this.floating=true;this.el=new Ext.Layer(typeof A=="object"?A:{shadow:this.shadow!==undefined?this.shadow:"sides",shadowOffset:this.shadowOffset,constrain:false,shim:this.shim===false?false:undefined},this.el)},getTopToolbar:function(){return this.topToolbar},getBottomToolbar:function(){return this.bottomToolbar},addButton:function(A,D,C){var E={handler:D,scope:C,minWidth:this.minButtonWidth,hideParent:true};if(typeof A=="string"){E.text=A}else{Ext.apply(E,A)}var B=new Ext.Button(E);B.ownerCt=this;if(!this.buttons){this.buttons=[]}this.buttons.push(B);return B},addTool:function(){if(!this[this.toolTarget]){return }if(!this.toolTemplate){var F=new Ext.Template("<div class=\"x-tool x-tool-{id}\">&#160;</div>");F.disableFormats=true;F.compile();Ext.Panel.prototype.toolTemplate=F}for(var E=0,C=arguments,B=C.length;E<B;E++){var A=C[E],G="x-tool-"+A.id+"-over";var D=this.toolTemplate.insertFirst((A.align!=="left")?this[this.toolTarget]:this[this.toolTarget].child("span"),A,true);this.tools[A.id]=D;D.enableDisplayMode("block");D.on("click",this.createToolHandler(D,A,G,this));if(A.on){D.on(A.on)}if(A.hidden){D.hide()}if(A.qtip){if(typeof A.qtip=="object"){Ext.QuickTips.register(Ext.apply({target:D.id},A.qtip))}else{D.dom.qtip=A.qtip}}D.addClassOnOver(G)}},onShow:function(){if(this.floating){return this.el.show()}Ext.Panel.superclass.onShow.call(this)},onHide:function(){if(this.floating){return this.el.hide()}Ext.Panel.superclass.onHide.call(this)},createToolHandler:function(C,A,D,B){return function(E){C.removeClass(D);E.stopEvent();if(A.handler){A.handler.call(A.scope||C,E,C,B)}}},afterRender:function(){if(this.fromMarkup&&this.height===undefined&&!this.autoHeight){this.height=this.el.getHeight()}if(this.floating&&!this.hidden&&!this.initHidden){this.el.show()}if(this.title){this.setTitle(this.title)}this.setAutoScroll();if(this.html){this.body.update(typeof this.html=="object"?Ext.DomHelper.markup(this.html):this.html);delete this.html}if(this.contentEl){var A=Ext.getDom(this.contentEl);Ext.fly(A).removeClass(["x-hidden","x-hide-display"]);this.body.dom.appendChild(A)}if(this.collapsed){this.collapsed=false;this.collapse(false)}Ext.Panel.superclass.afterRender.call(this);this.initEvents()},setAutoScroll:function(){if(this.rendered&&this.autoScroll){this.body.setOverflow("auto")}},getKeyMap:function(){if(!this.keyMap){this.keyMap=new Ext.KeyMap(this.el,this.keys)}return this.keyMap},initEvents:function(){if(this.keys){this.getKeyMap()}if(this.draggable){this.initDraggable()}},initDraggable:function(){this.dd=new Ext.Panel.DD(this,typeof this.draggable=="boolean"?null:this.draggable)},beforeEffect:function(){if(this.floating){this.el.beforeAction()}this.el.addClass("x-panel-animated")},afterEffect:function(){this.syncShadow();this.el.removeClass("x-panel-animated")},createEffect:function(B,A,C){var D={scope:C,block:true};if(B===true){D.callback=A;return D}else{if(!B.callback){D.callback=A}else{D.callback=function(){A.call(C);Ext.callback(B.callback,B.scope)}}}return Ext.applyIf(D,B)},collapse:function(B){if(this.collapsed||this.el.hasFxBlock()||this.fireEvent("beforecollapse",this,B)===false){return }var A=B===true||(B!==false&&this.animCollapse);this.beforeEffect();this.onCollapse(A,B);return this},onCollapse:function(A,B){if(A){this[this.collapseEl].slideOut(this.slideAnchor,Ext.apply(this.createEffect(B||true,this.afterCollapse,this),this.collapseDefaults))}else{this[this.collapseEl].hide();this.afterCollapse()}},afterCollapse:function(){this.collapsed=true;this.el.addClass(this.collapsedCls);this.afterEffect();this.fireEvent("collapse",this)},expand:function(B){if(!this.collapsed||this.el.hasFxBlock()||this.fireEvent("beforeexpand",this,B)===false){return }var A=B===true||(B!==false&&this.animCollapse);this.el.removeClass(this.collapsedCls);this.beforeEffect();this.onExpand(A,B);return this},onExpand:function(A,B){if(A){this[this.collapseEl].slideIn(this.slideAnchor,Ext.apply(this.createEffect(B||true,this.afterExpand,this),this.expandDefaults))}else{this[this.collapseEl].show();this.afterExpand()}},afterExpand:function(){this.collapsed=false;this.afterEffect();this.fireEvent("expand",this)},toggleCollapse:function(A){this[this.collapsed?"expand":"collapse"](A);return this},onDisable:function(){if(this.rendered&&this.maskDisabled){this.el.mask()}Ext.Panel.superclass.onDisable.call(this)},onEnable:function(){if(this.rendered&&this.maskDisabled){this.el.unmask()}Ext.Panel.superclass.onEnable.call(this)},onResize:function(A,B){if(A!==undefined||B!==undefined){if(!this.collapsed){if(typeof A=="number"){this.body.setWidth(this.adjustBodyWidth(A-this.getFrameWidth()))}else{if(A=="auto"){this.body.setWidth(A)}}if(typeof B=="number"){this.body.setHeight(this.adjustBodyHeight(B-this.getFrameHeight()))}else{if(B=="auto"){this.body.setHeight(B)}}}else{this.queuedBodySize={width:A,height:B};if(!this.queuedExpand&&this.allowQueuedExpand!==false){this.queuedExpand=true;this.on("expand",function(){delete this.queuedExpand;this.onResize(this.queuedBodySize.width,this.queuedBodySize.height);this.doLayout()},this,{single:true})}}this.fireEvent("bodyresize",this,A,B)}this.syncShadow()},adjustBodyHeight:function(A){return A},adjustBodyWidth:function(A){return A},onPosition:function(){this.syncShadow()},onDestroy:function(){if(this.tools){for(var B in this.tools){Ext.destroy(this.tools[B])}}if(this.buttons){for(var A in this.buttons){Ext.destroy(this.buttons[A])}}Ext.destroy(this.topToolbar,this.bottomToolbar);Ext.Panel.superclass.onDestroy.call(this)},getFrameWidth:function(){var B=this.el.getFrameWidth("lr");if(this.frame){var A=this.bwrap.dom.firstChild;B+=(Ext.fly(A).getFrameWidth("l")+Ext.fly(A.firstChild).getFrameWidth("r"));var C=this.bwrap.dom.firstChild.firstChild.firstChild;B+=Ext.fly(C).getFrameWidth("lr")}return B},getFrameHeight:function(){var A=this.el.getFrameWidth("tb");A+=(this.tbar?this.tbar.getHeight():0)+(this.bbar?this.bbar.getHeight():0);if(this.frame){var C=this.el.dom.firstChild;var D=this.bwrap.dom.lastChild;A+=(C.offsetHeight+D.offsetHeight);var B=this.bwrap.dom.firstChild.firstChild.firstChild;A+=Ext.fly(B).getFrameWidth("tb")}else{A+=(this.header?this.header.getHeight():0)+(this.footer?this.footer.getHeight():0)}return A},getInnerWidth:function(){return this.getSize().width-this.getFrameWidth()},getInnerHeight:function(){return this.getSize().height-this.getFrameHeight()},syncShadow:function(){if(this.floating){this.el.sync(true)}},getLayoutTarget:function(){return this.body},setTitle:function(B,A){this.title=B;if(this.header&&this.headerAsText){this.header.child("span").update(B)}if(A){this.setIconClass(A)}this.fireEvent("titlechange",this,B);return this},getUpdater:function(){return this.body.getUpdater()},load:function(){var A=this.body.getUpdater();A.update.apply(A,arguments);return this},beforeDestroy:function(){Ext.Element.uncache(this.header,this.tbar,this.bbar,this.footer,this.body)},createClasses:function(){this.headerCls=this.baseCls+"-header";this.headerTextCls=this.baseCls+"-header-text";this.bwrapCls=this.baseCls+"-bwrap";this.tbarCls=this.baseCls+"-tbar";this.bodyCls=this.baseCls+"-body";this.bbarCls=this.baseCls+"-bbar";this.footerCls=this.baseCls+"-footer"},createGhost:function(A,E,B){var D=document.createElement("div");D.className="x-panel-ghost "+(A?A:"");if(this.header){D.appendChild(this.el.dom.firstChild.cloneNode(true))}Ext.fly(D.appendChild(document.createElement("ul"))).setHeight(this.bwrap.getHeight());D.style.width=this.el.dom.offsetWidth+"px";if(!B){this.container.dom.appendChild(D)}else{Ext.getDom(B).appendChild(D)}if(E!==false&&this.el.useShim!==false){var C=new Ext.Layer({shadow:false,useDisplay:true,constrain:false},D);C.show();return C}else{return new Ext.Element(D)}},doAutoLoad:function(){this.body.load(typeof this.autoLoad=="object"?this.autoLoad:{url:this.autoLoad})}});Ext.reg("panel",Ext.Panel);
[/code]
Bon courage
Merci
I Am the best after the dog soup.
Tsvetina
Telerik team
 answered on 17 Jan 2012
3 answers
138 views
Hi,
   I have a textbox and a RadSlider control in my webpage. On dragging the radslider, the value inside the textbox will get changed.
Its working properly with all other browsers except IE9. In IE9, I am unable to drag the RadSlider control. I am using the RadAjax.Net2.dll of version 1.8.1.0.
Hope you guys will give me a good solution to resolve this issue. Waiting for your reply.

Regards,
Charles
Slav
Telerik team
 answered on 17 Jan 2012
3 answers
110 views
After uploading any file remove button gets cut the edges shown,Its looks weird in GUI.

Thanks,
Amit 
Plamen
Telerik team
 answered on 17 Jan 2012
1 answer
43 views
I'm asking for ideas.  I have a very large text file which I would like to present within a grid - or another viewer and have it "feel" like a text file.

So here is what I have:
We took a very large text file and reloaded into a table - line by line.  The table would look like this ..
line_number ---- line_value
1--------------------"the small"
2--------------------"red fox"
3--------------------"jumps over the fence"


Here is a challenge - Custom Paging:
This file contains million lines.  Far too many records to just pull out of the db and hand to a grid.  So I need custom paging or chunk/chapter processing.

So Ideas?
Are there any demos that might come close to a neat way to present this data?  We are working to implement grid custom paging but it would be nice to give it a feel of browsing through a file too.

Thanks for the thoughts.

Tim T.



Tsvetina
Telerik team
 answered on 17 Jan 2012
3 answers
131 views
Hi all,

I'm facing a strange behaviour. I have a RadComboBox, it is populated on server side, like this:

 

RadComboBox1.Items.Add(new Telerik.Web.UI.RadComboBoxItem("Value  1 - 1", "1")); 
RadComboBox1.Items.Add(new Telerik.Web.UI.RadComboBoxItem("Value  1 - 2", "1")); 
RadComboBox1.Items.Add(new Telerik.Web.UI.RadComboBoxItem("Value  1 - 3 ", "1")); 
RadComboBox1.Items.Add(new Telerik.Web.UI.RadComboBoxItem("Value  2", "2"));

As can be see, three items have the same value (1). The problem is, in the client side, I select a item, for exemple, "Value 1 - 3", so, when the combobox last the focus, the item will be automatic set to "Value 1 - 1".

Why this happen? Is there a way to stop this?

Thanks.

Kalina
Telerik team
 answered on 17 Jan 2012
1 answer
153 views
Hi all, I'm having an issue trying to get the right look for our grid.
The Grid autogenerates all the columns, but in the edit mode the grid expands the whole page and sometimes it creates an horizontal scroll at page level, what I want to do is that the grid respects the specified grid's width and if necessary enlarge the horizontal scroll at grid level. My aspx code is something like this:

<telerik:RadGrid id="{@id}" runat="server" AutoGenerateColumns="True" AllowMultiRowSelection="True"
    AllowMultiRowEdit="True" MasterTableView-EditMode="InPlace" Skin="Windows7"Width="50%">
    <HeaderContextMenu EnableAutoScroll="True"/>
    <MasterTableView DataSourceID="{@id}_" HorizontalAlign="NotSet">
      <Columns>
          <telerik:GridEditCommandColumn ButtonType="ImageButton" UniqueName="EditCommandColumn">
            <ItemStyle CssClass="MyImageButton" />
          </telerik:GridEditCommandColumn>
      </Columns>
      <EditFormSettings ColumnNumber="2"  InsertCaption="New">
        <FormTableItemStyle Wrap="False" />
        <FormCaptionStyle CssClass="EditFormHeader" />
        <FormMainTableStyle GridLines="None" CellSpacing="0" CellPadding="3" BackColor="White" Width="100%" />
        <FormTableStyle CellSpacing="0" CellPadding="2" Height="110px" BackColor="White" />
        <FormTableAlternatingItemStyle Wrap="False" />
        <EditColumn ButtonType="ImageButton" InsertText="Insert record" UpdateText="Update record"
            UniqueName="EditCommandColumn1" CancelText="Cancel edit" />
        <FormTableButtonRowStyle HorizontalAlign="Right" CssClass="EditFormButtonRow" />
      </EditFormSettings>
    </MasterTableView>
    <ClientSettings  AllowColumnsReorder="True" ReorderColumnsOnClient="false">
        <Selecting AllowRowSelect="True" EnableDragToSelectRows="false"/>
        <Scrolling AllowScroll="True" UseStaticHeaders="True" />
    </ClientSettings>
</telerik:RadGrid>

And i hooked the ColumnCreated event for preventing to wrap, like this:

protected void RadGrid1_ColumnCreated(object sender, GridColumnCreatedEventArgs e){
    if (e.Column is GridBoundColumn)
    {
        (e.Column as GridBoundColumn).DataFormatString = "<nobr>{0}</nobr>";
    }
}

I attached screenshots that represent the actual grid behaviour in edit mode...

Thanks in advance,
Diego.
Tsvetina
Telerik team
 answered on 17 Jan 2012
1 answer
202 views
Hi

I am trying to export the html content below to PDF format via the RadEditor:

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"><html><head><META http-equiv="Content-Type" content="text/html; charset=utf-16"><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"><title>INTELLIGENCE SERVICES CONTROL ACT NO. 40 OF 1994</title><link type="text/css" rel="stylesheet" href="/templates/BWCommon.css"><link type="text/css" rel="stylesheet" href="/mylnb/SiteCommon.css"><script type="text/javascript" src="/templates/vendor/jquery-1.6.1.min.js"></script><script type="text/javascript" src="/templates/links.js"></script><script type="text/javascript" src="/templates/popup.js?2"></script><script type="text/javascript" src="/templates/hoverbox.js?2"></script></head><body><p class="Generator-Heading" style="text-align:center">To browse use the Table of Contents on the left or the links provided below.</p><p><br></p><p class="Generator-Heading">Contents</p><p class="Generator-Item" style="margin-left:15pt"><a href="../../../jilc">Legislation - South Africa - National</a></p><p class="Generator-Item" style="margin-left:30pt"><a href="../../kilc">Acts and Regulations</a></p><p class="Generator-Item" style="margin-left:45pt"><a href="../alrg">I</a></p><p class="Generator-Item" style="margin-left:45pt;color:#00267F;margin-top:12pt"><b>  <img style="border:0" width="8" height="9" src="/templates/arrows.gif" alt="">  INTELLIGENCE SERVICES CONTROL ACT NO. 40 OF 1994</b></p><p><br><br></p><p><br><br></p></body></html>

But this fails with the following exception : 
Exception Details: System.Xml.XmlException: Invalid XHTML. RadEditor content should be correct XHTML in order to export to PDF.

What encoding does the XHTML validation use? And can it be set somewhere?

Thanks.


Rumen
Telerik team
 answered on 17 Jan 2012
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?