Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
53 views
Hi all.

I posted a reply to this post ( http://www.telerik.com/community/forums/aspnet-ajax/grid/grid-renders-differently-from-development-when-in-production.aspx#963065 ) yesterday but wanted to start a fresh post incase no one is monitoring that post any more

I have a grid with a filter row that renders incorrectl when IE8 is used in compatibility mode. I have attached 3 images to show what they look like in different scenarios..

Image 1 shows the header of my grid in IE8 with compatibility mode turned off.
Image 2 shows the same header in the same browser with compatibility turned on.
Image 3 shows the same setup as image2, but with the FilterControlWidth set to 50px, which is much narrower than the filter icon's required space.

The code for the first column (Customer Reference) is shown here...

This is the same code used to generate Image 1 and Image 2.
<telerik:GridBoundColumn 
        HeaderText="Customer reference"
        DataField="External_Document_No"
        SortExpression="External_Document_No"
        FilterControlWidth="108px"
        FilterListOptions="VaryByDataType"
        >
    <HeaderStyle    HorizontalAlign="Left"      Width="158px" />
    <ItemStyle      HorizontalAlign="Left"      Width="158px" />
</telerik:GridBoundColumn>

This is the code used to generate Image 3...
<telerik:GridBoundColumn 
        HeaderText="Customer reference"
        DataField="External_Document_No"
        SortExpression="External_Document_No"
        FilterControlWidth="50px"
        FilterListOptions="VaryByDataType"
        >
    <HeaderStyle    HorizontalAlign="Left"      Width="158px" />
    <ItemStyle      HorizontalAlign="Left"      Width="158px" />
</telerik:GridBoundColumn>

It seems that the FilterControlWidth option is only setting the textbox and not the overall width of the filter item (the textbox and the filter button)

Any ideas why the filter row doesn't all sit nice and neatly on one row?
Pavlina
Telerik team
 answered on 13 Jul 2011
2 answers
233 views
Hello,

I am using the RadGrid and I initialize it dynamicaly with a DataTable.

I want to get the different values I updated in the UpdateCommand events, but I can't find it with the GridCommandEventArgs.

Could you help me?


thanks.
Donatien
Top achievements
Rank 1
 answered on 13 Jul 2011
3 answers
51 views
Hi !

I have used radcombo box in my custom webpart coding for moss 2007. And I have my own style sheet. The width of this control is not set.

How can I overwrite the radcombo  box default style sheet?

Environment details
----------------------------------------------
Windows 2003
Sharepoint 2007
IIS 6.0
Telerik 2010.3.1109.20


Can you tell me the correct way?

Thanks in advance.


Dimitar Terziev
Telerik team
 answered on 13 Jul 2011
1 answer
69 views
Hi,
I use entity datasource for the tabstrip, but in the TabSelected event, the dataItem for the selected tab is 'nothing'. (I use templates for tabs)

How to get the dataitem in the 'tabselected' event

ex:

    Protected Sub TabSelected(ByVal sender As Object, ByVal e As RadTabStripEventArgs)
        Me.uxTabStrip.SelectedIndex = e.Tab.Index
        Dim entity= TryCast(e.Tab.DataItem, entity)
    End Sub

##  entity is 'Nothing' here 

regards,
Naresh
Dimitar Terziev
Telerik team
 answered on 13 Jul 2011
3 answers
81 views
Hi,

How can we find that , user has clicked the Navigation Right & Left (> & <),FastNavigation Left & Right (>> & << ) From Client Side and Server side, I want to be do some custome navigation for My requirement. and How can we find the Paritcular Date (Dynamic Date) and make that date as bold (Not Selecting , Just finding the Date ). we can check in the DayRender Event , but  i dont want to check in that, because it ll check for every refresh. i want to check only one time . Can you suggest me how to do?
Shinu
Top achievements
Rank 2
 answered on 13 Jul 2011
3 answers
213 views
v.2010.3.1317.40

I am using the grid client side databinding with vertical scrolling and static headers. I initially set the page size to 50 so the scrolling takes affect when the grid is bound. On the gui when i change the page size or filter the grid so that the scroll bar becomes unnecessary the grid header and item rows become misaligned. This misalignment happens on IE9/IE9 Compatibility, Chrome, FireFox, and Opera. The grid is in a div width 950px. I have also tried removing all header widths and div width and the misalignment still happens. I am not using ItemStyle-Widths or GridLine properties. Here is the grid and the type of client side databinding. Also i have attached the images of what is happening.

How do i get the header and item rows to align when I change the page size or filter?

I did just see something interesting happen as i was entering this post and retesting the grid. I was using IE9 with the menu bar hidden. I then changed the page size and the grid misaligned. I then clicked alt to show the menu and the grid aligned itself. If i could make the grid do this when after databinding thing would be great.

<telerik:RadGrid ID="gProducts" runat="server" AllowPaging="true" AllowSorting="true" AutoGenerateColumns="false" PageSize="50"
           AllowMultiRowSelection="true" Width="100%">
           <ItemStyle Font-Size="8pt" Height="10px" />
           <AlternatingItemStyle Font-Size="8pt" Height="10px" />
           <PagerStyle Mode="NextPrevAndNumeric" AlwaysVisible="true" />
           <ClientSettings>
               <Scrolling AllowScroll="true" ScrollHeight="100%" UseStaticHeaders="true" />
               <ClientEvents OnCommand="gProducts_Command" />
               <Selecting AllowRowSelect="true" />
           </ClientSettings>
           <MasterTableView ClientDataKeyNames="StockingListItemID" CommandItemDisplay="Top" TableLayout="Auto">
               <CommandItemTemplate>
                   <div style="height: 30px; text-align: right;">
                       <asp:Button ID="imgCancelChanges" runat="server" Text="Cancel" ToolTip="Cancel changes" Height="24px" Style="cursor: pointer;
                           margin: 2px 5px 0px 0px;" OnClientClick="CancelChanges(); return false;" />
                       <asp:Button ID="imgProcessChanges" runat="server" Text="Save" ToolTip="Save changes" Height="24px" Style="cursor: pointer;
                           margin: 2px 5px 0px 0px;" OnClientClick="ProcessChanges(); return false;" />
                       <asp:Button ID="btnEditMarkup" runat="server" Text="Edit Selected Rows" Height="24px" Style="cursor: pointer; margin: 2px 5px 0px 0px;"
                           OnClientClick="OpenWindow(); return false;" />
                   </div>
               </CommandItemTemplate>
               <Columns>
                   <telerik:GridBoundColumn UniqueName="SKU" DataField="SKU" HeaderText="Product #" ReadOnly="True" HeaderStyle-Width="80px" />
                   <telerik:GridBoundColumn UniqueName="ProductName" DataField="ProductName" HeaderText="Product Name" ReadOnly="True" HeaderStyle-Width="200px" />
                   <telerik:GridBoundColumn UniqueName="ManufacturerPartNumber" DataField="ManufacturerPartNumber" HeaderText="Mfg #" ReadOnly="True"
                       HeaderStyle-Width="85px" />
                   <telerik:GridBoundColumn UniqueName="ManufacturerName" DataField="ManufacturerName" HeaderText="Mfg Name" ReadOnly="True"
                       HeaderStyle-Width="155px" />
                   <telerik:GridBoundColumn UniqueName="Cost" SortExpression="" DataField="Cost" HeaderText="" DataFormatString="{0:c}" ReadOnly="True"
                       HeaderStyle-Width="60px" />
                   <telerik:GridTemplateColumn UniqueName="Markup" HeaderText="Markup" SortExpression="Markup" HeaderStyle-Width="80px">
                       <ItemTemplate>
                           <telerik:RadNumericTextBox ID="txtMarkup" ShowSpinButtons="true" IncrementSettings-InterceptArrowKeys="true" IncrementSettings-InterceptMouseWheel="true"
                               runat="server" MinValue="0" MaxValue="100" Type="Percent" Width="75px" Height="10px">
                               <ClientEvents OnValueChanged="markupChanged" />
                           </telerik:RadNumericTextBox>
                       </ItemTemplate>
                   </telerik:GridTemplateColumn>
                   <telerik:GridBoundColumn UniqueName="GlobalMarkup" DataField="GlobalMarkup" HeaderText="Gl Markup" DataFormatString="{0:p}"
                       HeaderTooltip="Global Markup" ReadOnly="True" HeaderStyle-Width="75px" />
                   <telerik:GridBoundColumn UniqueName="Price" SortExpression="" DataField="Price" HeaderText="Price" DataFormatString="{0:c}"
                       ReadOnly="True" HeaderStyle-Width="60px" />
               </Columns>
           </MasterTableView>
       </telerik:RadGrid>

function updateGrid(result) {
 tableView.set_dataSource(result.d);
 tableView.dataBind();
}
Manoj
Top achievements
Rank 1
 answered on 13 Jul 2011
1 answer
98 views
Hi,

Here I need to select parent and based on parent selection all childs should be selected. I got the code of HeaderItem checkbox but Its not solving my problem as I am unable to find TreeListSelectColumn at page_prerender to register JS onclick of its checked event.

Is there any solution by which I can select any of the parent in radtreelist and related childs will be select?

Thanks & Regards,

Kaushal Jani
Kaushal
Top achievements
Rank 1
 answered on 13 Jul 2011
1 answer
103 views
Hi,

I have one grid and i have set CommandItemSettings-AddNewRecordText on this grid. When clicks on this Add New i am getting one insert row in Grid to enter new data then to Insert data in DB i am doing my functionality on RadGrid_ItemCommand by checking e.CommandName == RadGrid.PerformInsertCommandName. Upto here everything working fine. Data is inserting in DB and all. but just after that a new row shows in grid to insert new data and i don't want.

How to do that i will not get this new insert row in grid just after inserting data ? I want user will click again the Add new on Grid header to get this new insert row in grid to insert new data. 

Thanks,
--Jai
Jai
Top achievements
Rank 1
 answered on 13 Jul 2011
1 answer
65 views
I am looking to show a different context menu, based on the value of a cell when right clicking on a row. For example. I have a grid, that displays a list of emails. One of the cells in the grid is an Boolean, called isread. If the value is true, when I right click on the email. I want an option to "Mark as Unread" If the value is false, I want to display "Mark as Read" 

Any assistance in how to do this, and if it is possible would be greatly appreciated. 
Shinu
Top achievements
Rank 2
 answered on 13 Jul 2011
2 answers
162 views
Hi!
We have an ASP.NET page with a lot of Rad controls including (Textboxes, Lists, comboboxes) and a RadGrid. I'm trying to improve the performance of the page and currently about 35% of the page size is occupied by the script blocks of Rad controls. Example of the javascript statements are mentioned below and these get repeated for each control. I'm guessing that this gets generated on-the-fly when the control is spitted out to HTML.

Is there a way one could compress/minimize the javascript code on the page? Any help/suggestions would be appreciated.


------------Example Javascript function calls on the page ----------
Sys.Application.add_init(function() {
    $create(Telerik.Web.UI.RadTextBox, {"_focused":false,"_postBackEventReferenceScript":"setTimeout(\"__doPostBack(\\\u0027ctl00$PageContent$woMaint$tbxRateSchedule\\\u0027,\\\u0027\\\u0027)\", 0)","_skin":"WebBlue","clientStateFieldID":"ctl00_PageContent_woMaint_tbxRateSchedule_ClientState","enabled":true,"styles":{HoveredStyle: ["width:50%;", "riTextBox riHover"],InvalidStyle: ["width:50%;", "riTextBox riError"],DisabledStyle: ["width:50%;", "riTextBox riDisabled"],FocusedStyle: ["width:50%;", "riTextBox riFocused"],EmptyMessageStyle: ["width:50%;", "riTextBox riEmpty"],ReadOnlyStyle: ["width:50%;", "riTextBox riRead readonly"],EnabledStyle: ["width:50%;", "riTextBox riEnabled"]}}, null, null, $get("ctl00_PageContent_woMaint_tbxRateSchedule"));
});
Sys.Application.add_init(function() {
    $create(Telerik.Web.UI.RadTextBox, {"_focused":false,"_postBackEventReferenceScript":"setTimeout(\"__doPostBack(\\\u0027ctl00$PageContent$woMaint$tbxLoanType\\\u0027,\\\u0027\\\u0027)\", 0)","_skin":"WebBlue","clientStateFieldID":"ctl00_PageContent_woMaint_tbxLoanType_ClientState","enabled":true,"styles":{HoveredStyle: ["width:80px;", "riTextBox riHover"],InvalidStyle: ["width:80px;", "riTextBox riError"],DisabledStyle: ["width:80px;", "riTextBox riDisabled"],FocusedStyle: ["width:80px;", "riTextBox riFocused"],EmptyMessageStyle: ["width:80px;", "riTextBox riEmpty"],ReadOnlyStyle: ["width:80px;", "riTextBox riRead readonly"],EnabledStyle: ["width:80px;", "riTextBox riEnabled"]}}, null, null, $get("ctl00_PageContent_woMaint_tbxLoanType"));
});
Johny
Top achievements
Rank 1
 answered on 13 Jul 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?