Telerik Forums
UI for ASP.NET AJAX Forum
6 answers
390 views

Hi,

I have this weird behaviour on one of my radgrid where the height is cut off. So the area where the rows are displayed are shorter ( I think its the rgDataDiv) .I have to say the page i have it it is quiet complex and involves a lot of dynamic controls... not sure if this is the cause...but this behaviour is only seen after a sequence of clicks ( i can always reproduce it ).

Landing on the page originally does not show the bug, but after a series of clicks ( a consistent pattern ) it happens... I'm gonna try to post my grid source and the behaviour and the generated HTML first to see... hopefully its just a stupid setting i forgot to set which you can point out...

Otherwise, If required, I'll post the full page...
Here's the Grid... Notice I've forced it to have a height of 493px.

<div style="margin-left: 12px; margin-top: 40px; clear: both;">
    <%--Grid Selected Shopping List--%>
    <telerik:RadGrid ID="grdSelectedList" runat="server" AutoGenerateColumns="False"
        CellSpacing="0" GridLines="None" ShowHeader="False" OnNeedDataSource="grdSelectedList_NeedDataSource"
        OnItemCommand="grdSelectedList_ItemCommand" OnItemCreated="grdSelectedList_ItemCreated"
        OnItemDataBound="grdSelectedList_ItemDataBound" Height="493px" Width="595px"
        Skin="gmBlueGrid" EnableEmbeddedSkins="False" Style="outline: none;" EnableViewState="false">
        <GroupingSettings ShowUnGroupButton="True" />
        <ClientSettings>
            <Selecting AllowRowSelect="True" />
            <Scrolling AllowScroll="True" UseStaticHeaders="True" />
            <ClientEvents OnRowClick="grdSelectedList_RowClick" />
        </ClientSettings>
        <MasterTableView DataKeyNames="Account_ID, Item_ID, List_ID, Product_ID"
            ClientDataKeyNames="Account_ID, Item_ID, List_ID, Product_ID">
            <GroupByExpressions>
                <telerik:GridGroupByExpression>
                    <SelectFields>
                        <telerik:GridGroupByField FieldName="Category_Name" />
                    </SelectFields>
                    <GroupByFields>
                        <telerik:GridGroupByField FieldName="Category_Name" />
                    </GroupByFields>
                </telerik:GridGroupByExpression>
            </GroupByExpressions>
            <NoRecordsTemplate>
                This list is empty.<br />
                Click in "Add an Item" or "Browse Aisles" to add items to this list.
            </NoRecordsTemplate>
            <CommandItemSettings ExportToPdfText="Export to PDF" />
            <RowIndicatorColumn FilterControlAltText="Filter RowIndicator column">
                <HeaderStyle Width="20px" />
            </RowIndicatorColumn>
            <ExpandCollapseColumn FilterControlAltText="Filter ExpandColumn column">
                <HeaderStyle Width="20px" />
            </ExpandCollapseColumn>
            <Columns>
                <telerik:GridBoundColumn FilterControlAltText="Filter CategoryCol column" UniqueName="CategoryCol"
                    DataField="Category_Name" Groupable="true" Visible="False">
                </telerik:GridBoundColumn>
                <telerik:GridTemplateColumn FilterControlAltText="Filter DescriptionCol column" UniqueName="DescriptionCol"
                    HeaderStyle-Width="455px">
                    <ItemTemplate>
                        <div style="width: 455px; clear: both; font-weight: bold; margin-left: -5px;">
                            <asp:Label ID="lblItemDescription" runat="server" CssClass="blackHyperlink"></asp:Label>
                        </div>
                        <div class="slGridDescription" style="margin-left: -5px;">
                            <%# DataBinder.Eval(Container.DataItem, "Detail_Line_Display") %></div>
                    </ItemTemplate>
                    <HeaderStyle Width="455px"></HeaderStyle>
                </telerik:GridTemplateColumn>
                <telerik:GridBoundColumn FilterControlAltText="Filter QtyCol column" UniqueName="QtyCol"
                    DataField="Size_Description" HeaderStyle-Width="70px" ItemStyle-Font-Bold="true"
                    ItemStyle-HorizontalAlign="Right">
                    <HeaderStyle Width="70px"></HeaderStyle>
                    <ItemStyle HorizontalAlign="Right" Font-Bold="True"></ItemStyle>
                </telerik:GridBoundColumn>
                <telerik:GridTemplateColumn>
                    <ItemTemplate>
                        <telerik:RadButton ID="btnDeleteItem" runat="server" CommandName="DeleteItemFromShoppingList"
                            OnClientClicking="ConfirmDelete" Width="18" Height="20">
                            <Image ImageUrl="..\Images\icoDeleteRedX.gif" />
                        </telerik:RadButton>
                    </ItemTemplate>
                </telerik:GridTemplateColumn>
            </Columns>
            <EditFormSettings>
                <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                </EditColumn>
            </EditFormSettings>
        </MasterTableView>
        <FilterMenu EnableImageSprites="False">
            <WebServiceSettings>
                <ODataSettings InitialContainerName="">
                </ODataSettings>
            </WebServiceSettings>
        </FilterMenu>
        <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Default">
            <WebServiceSettings>
                <ODataSettings InitialContainerName="">
                </ODataSettings>
            </WebServiceSettings>
        </HeaderContextMenu>
    </telerik:RadGrid>
    <br />
</div>

Attached are 4 images:
Generated HTML output of the Grid before; Note the height in the outer div of height 493px and the inner rgDataDiv ( I'm assuming it is inherited from the RadGrid declaration )
Generated HTML output of the Grid after; the height of outer div is still 493, but the rgDataDiv is now set to 300 px? Not sure where this comes from .
Display Before and After


Additional Information regarding the set up , in case it is related to the way this grid is set up:
I have modified the gridCSS so that it displays according to a spec i received... The Rows are always grouped by the category ...

Regarding the Page / UC set up, I have a Page 1 which uses a Master Template. In the Page, it has 3 states ( 3 custom NON-Telerik TABS ). By default it calls this dynamic UC (call it TAB 1) which has the RadGrid. When I Click on TAB 3, it calls another Dynamic UC replacing the content of the placeholder completely. Now I leave this page to Page 2, then come back to Page 1. This time, because I have a Session variable to save the state of the last Visited TAB in page 1, It loads Page 1 with TAB 3. When I click on TAB 1, to display the RadGrid , this is where this behaviour is obtained.

Pavlina
Telerik team
 answered on 13 Jan 2012
0 answers
65 views
I have inherited a report which has been bound at design time using the front end tools/wizards.
A datasource has been bound to a control but there is another control on the report which wants to use a subset of that datasource. Basically it needs to get the number of records where the addedDate field is within the last 6 months.
I thought I would be able to copy the datasource into a datatable and loop through them chacking the date manually but it wont let me cast the datasource as a datatable.
Any ideas how to work around this?
Paul
Top achievements
Rank 1
 asked on 13 Jan 2012
1 answer
56 views
I am trying to bind a RadGrid to a generic list of business objects using the OnNeedDataSource event. The grid displays the correct number of rows, however, the values for the fields are empty. I can bind to a datasource object without a problem, but I am going to be adding additional functionality where this method will be necessary. For simplicity sake, I am just trying to bind a single exposed property from the custom class object in the list.

.ASPX
<formid="form1"runat="server"
    <telerik:RadScriptManagerID="RadScriptManager1"  runat="server"
            
    </telerik:RadScriptManager
    <div
     <telerik:RadGridrunat="server"AllowPaging="True"ID="RadGrid2"OnNeedDataSource="RadGrid2_NeedDataSource"Width="600px"PageSize="8"
            <MasterTableViewWidth="100%"
                <Columns
                     <telerik:GridBoundColumnHeaderText="Project Name"DataField="name"></telerik:GridBoundColumn
                </Columns
                <NoRecordsTemplate
                    <divstyle="height: 30px; cursor: pointer;"
                        No items to view</div
                </NoRecordsTemplate
                <PagerStyleMode="NumericPages"PageButtonCount="4"/> 
            </MasterTableView
        </telerik:RadGrid
    </div
    </form>

ASPX.VB
Public Class bookmarks 
    Inherits System.Web.UI.Page 
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load 
    
    End Sub 
    Protected Sub RadGrid2_NeedDataSource(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridNeedDataSourceEventArgs) Handles RadGrid2.NeedDataSource 
        RadGrid2.DataSource = getBookMarks 
    End Sub 
    Private ReadOnly Property getBookMarks() As IList(Of project) 
        Get 
            Dim strSQL As String = "SELECT PROJ_NAME FROM [OPI_TIMESHEETS] o left outer join DCSC_PROJECT d on o.project_number = d.PROJ_NO " 
            Dim results As IList(Of project) = New List(Of project)() 
            Using connection As IDbConnection = DbProviderFactories.GetFactory("System.Data.SqlClient").CreateConnection() 
                connection.ConnectionString = ConfigurationManager.ConnectionStrings("projcentral").ConnectionString 
    
                Using command As IDbCommand = connection.CreateCommand() 
                    command.CommandText = strSQL 
    
                    connection.Open() 
                    Try 
                        Dim reader As IDataReader = command.ExecuteReader() 
                        While reader.Read() 
                            Dim name As String = reader.GetValue(reader.GetOrdinal("PROJ_NAME")) 
                            results.Add(New project(name)) 
                        End While 
    
                    Catch ex As SqlException 
                        results.Clear() 
                        'lblmsg.Text = ex.Message 
                    End Try 
                End Using 
            End Using 
            lblMsg.Text = results.Count & " items in list" 
            Return results 
    
        End Get 
    End Property 
    Class project 
    
        Private _projName As String 
    
        Sub New(ByVal name As String) 
    
            _projName = name 
    
        End Sub 
#Region "properties" 
    
        Private ReadOnly Property Name() As String 
            Get 
                Return _projName 
            End Get 
        End Property 
    
#End Region 
    End Class 
    
End Class
Maria Ilieva
Telerik team
 answered on 13 Jan 2012
3 answers
165 views

Dear Support,

I've issue with the image button. The button image blinks when the user hover over the Button, then when the user move out from the button the image appears again.

Please find the attached images.

Here is my markup code for the button.

 

<rad:RadButton ID="btnAccountStatusHistory" runat="server" Text="Status History"
           OnClientClicking="OnAccountStatusHistoryClientClicking">
           <Icon PrimaryIconUrl="~/_Images/ButtonsIcons/History.gif" PrimaryIconLeft="4" PrimaryIconTop="4" />
</rad:RadButton>

Your help is really appreciated to solve this weird behavior.

Slav
Telerik team
 answered on 13 Jan 2012
1 answer
86 views
I am using the RadComboBox to display a list of employees, along with their employee numbers (in the same field, in parentheses). The employee numbers have a fixed two character prefix ("NB") followed by 6 digits ("NB000342", "NB191561", etc). So the field in the combo drop down looks like "Smith, John (NB117654)". I am loading the full list on-demand. The filtering works fine until you type a digit, then it returns nothing. It matters not whether you type only digits or whether you mix digits and text; the presence of any digit(s) results in no matches. Is there a setting that I am missing that enables alphanumeric filtering?
Mark
Top achievements
Rank 1
 answered on 13 Jan 2012
0 answers
81 views
Hi everyone/ I'm currently using RadScheduler to create my own Scheduler. For better user experience, I used Web service binding, but only the GetAppointments is invalid. I use my own Advance Template with no resource, only passing extra attributes. 
But eveytime when I Update or Insert, a message box appears with the text "Invalid web service call, missing value for parameter 'appointmentData'".
Hoang Lam
Top achievements
Rank 1
 asked on 13 Jan 2012
1 answer
58 views
Hi,

In my page I have telerik grid, in that some rows are repeated. I need to show the repeated rows in group panel. If I add the group expression in my code, the group panel will come for all the rows in grid. Is it possible to put the group panel only for the repeated data(rows) in the grid. Thanks in advance.

Thanks,
Akki
Jayesh Goyani
Top achievements
Rank 2
 answered on 13 Jan 2012
10 answers
180 views
Hi I have MasterPage/Content page scenario the Content page loads a ModalPopup using the AjaxControlToolkit that loads a user control that has a RadGrid inside a FormView controls EditItemTemplate. The problem is that the FilterMenu/Group By etc only shows up behind the modal popup and is not click able. The same issue for that pager of the RadGrid in that it's Page size combo is not selectable.

I have tried the following:-
1). In the RadGrid's Init event setting the RadGrid style to a higher z-index than the popup
2). changing the FilterMenu and HeaderContextMenu CssClass to one with a higher z-index
3). Setting the RadComboBox in the pager to have a style with a higher z-index

but none of this works. What do I try next??
Marin
Telerik team
 answered on 13 Jan 2012
6 answers
330 views
Hello,

I have a grid with group headers. Grid has 3 columns. 2 columns are right aligned while one is left aligned.

I wish to have group header text also right aligned.

Please let me know I can achieve the same ?

Please see attached image for more info.
Dhilip
Top achievements
Rank 1
 answered on 13 Jan 2012
1 answer
301 views
Hey peeps,

I've got a strange problem happening. We're busy with a website that consists of 2 sections that accesses the same RadGrid. The first section is based on the programme selection by the user (e.g. Home Page -> Programme -> Sub Programme -> Tools Tab). The second section can be accessed directly (e.g. Home Page -> Resources). Both pages are different as the Resources page is a summary of all documents and the programme page contains documents related to that specific programme. On both pages we have a RadGrid that works great.

Now for the problem. On that RadGrid there is an item template that contains a button to allow the user to view the contents of the selected document category. Once clicked, a new RadWindow is opened containing a RadGrid, listing all the documents in that category. Both pages (programme and resources) access the same page that contains the radgrid displayed in the radwindow (lets call it ContentPage).

When the ContentPage is opened from the Programme page, the RadGrid shows 100%. However, when the same ContentPage is opened from the Resources page, the RadGrid does not show. Any ideas?
Tsvetina
Telerik team
 answered on 13 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?