Telerik Forums
UI for ASP.NET AJAX Forum
2 answers
107 views
I am running Google Chrome version 10.0.648.134 and going through the demos, it does not operate correctly.

For example, on the Grid demo | Outlook Grid located at http://demos.telerik.com/aspnet-ajax/grid/examples/programming/webmail/defaultcs.aspx, I click on the Rate / Review button in top right corner and nothing appears (it does detect hover state and changes the style of the button.  When I click on a row to select it, nothing happens (it should select the row and highlight it in an orange/gold color).  Multi selection does not work either.  I click the checkboxes in the first 3 rows and then click on the post back button at the bottom of the grid, it refreshes with the grid but nothing is selected (state is not preserved).

All this does work fine on Google Chrome 9.0.597.98, Microsoft IE 8.0.7600.16385, Firefox 3.6.13.

Ed Lamprecht
Maria Ilieva
Telerik team
 answered on 21 Mar 2011
1 answer
171 views
Hey there,

i've a combobox inside griditem template column.I m using linq data source to populate this

<telerik:GridTemplateColumn HeaderText="Product ID" HeaderStyle-Font-Bold="true"
                                AllowFiltering="true" DataField="ProductID">
                                <EditItemTemplate>
                                    <telerik:RadComboBox ID="RadCbProductIDEdit" Skin="Office2007" runat="server" MarkFirstMatch="true"
                                        AllowCustomText="true" DataValueField="ProductID" EmptyMessage="Please select a ProductID "
                                        DataTextField="ProductID" DataSourceID="LinqDataSource1" Height="100px">
                                    </telerik:RadComboBox>
                                </EditItemTemplate>
                                <InsertItemTemplate>
                                    <telerik:RadComboBox ID="RadcbProductIDInsert" runat="server" Skin="Office2007" MarkFirstMatch="true"
                                        AllowCustomText="true" DataValueField="ProductID" EmptyMessage="Please select a ProductID "
                                        DataTextField="ProductID" DataSourceID="LinqDataSource1" Height="100px">
                                    </telerik:RadComboBox>
                                </InsertItemTemplate>
                                <ItemTemplate>
                                    <asp:Label ID="lblProductID" runat="server" Text='<%# Bind("ProductID") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle Font-Bold="True" />
                            </telerik:GridTemplateColumn>
 
 
<asp:LinqDataSource ID="LinqDataSource1" runat="server"
            ContextTypeName="LPSFPrototypeScreens.tblProduct" EntityTypeName=""
            Select="new (ProductID)" TableName="tblProductFeatures" >
also here ProductID is FK.
what cud be the reason??...

Thanks
Amit
Elliott
Top achievements
Rank 2
 answered on 21 Mar 2011
5 answers
807 views
I am trying to export a programmatically created radgrid to excel.  I am exporting Data only.  I tried to export as HTML, but that caused Excel to freeze up.  (Passing 1,000 records.)  Part of the export requires that I change the styling on the items (background color), and the other part changes the dataformatstring to {0:C} for currency fields.

Is there a way to accomplish this?  I tried a few suggestions I saw on here, but I'm stumped.  Any help is appreciated.  Thank you.

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click
    Dim radgrid2 As New RadGrid
    radgrid2.AutoGenerateColumns = True
    radgrid2.ID = "RadGrid2"
    Me.PlaceHolder1.Controls.Add(radgrid2)
 
    connSql.ConnectionString = sqlConn.ToString()
 
    Dim poSqlCom As New SqlCommand("dbo.getCurrQtrAll", connSql)
    poSqlCom.CommandType = CommandType.StoredProcedure
    poSqlCom.Parameters.AddWithValue("@UID", "SomeoneElse")
 
 
    Dim adapter As New SqlDataAdapter(poSqlCom)
    Dim links As New DataTable()
 
    Try
        adapter.Fill(links)
    Catch ex As Exception
        'lblResult.Text = ex.Message
        If connSql.State = ConnectionState.Open Then
            connSql.Close()
        End If
    End Try
 
    radgrid2.DataSource = links
    radgrid2.Rebind()
 
    radgrid2.ExportSettings.Excel.FileExtension = "xls"
    radgrid2.ExportSettings.FileName = "Cur_Qtr_Rpt"
    radgrid2.ExportSettings.ExportOnlyData = True
    radgrid2.ExportSettings.IgnorePaging = True
    radgrid2.ExportSettings.Excel.Format = GridExcelExportFormat.ExcelML
    radgrid2.MasterTableView.ExportToExcel()
End Sub
GP
Top achievements
Rank 1
 answered on 21 Mar 2011
1 answer
97 views
I would like to know if it's possible to persist expanded or collapsed groups on postback.

Basically whenever I set a filter or start editing a record a postback occurs and all the groups are set to default (expanded).

Here's my grid code.

    <telerik:RadGrid ID="timesheetGrid" runat="server" GridLines="None" Skin="Windows7"
        AllowSorting="True" ShowGroupPanel="True" AutoGenerateColumns="False" AllowPaging="True"
        PageSize="15" ShowStatusBar="True" AllowFilteringByColumn="True" AllowMultiRowSelection="True"
        OnNeedDataSource="timesheetGrid_NeedDataSource" OnPreRender="timesheetGrid_PreRender"
        ViewStateMode="Enabled" HeaderStyle-HorizontalAlign="Center" OnEditCommand="timesheetGrid_EditCommand">
        <ClientSettings EnableRowHoverStyle="true" AllowColumnsReorder="True" ReorderColumnsOnClient="True"
            AllowDragToGroup="True">
            <Selecting AllowRowSelect="True" />
            <ClientEvents OnRowDblClick="RowDblClick" />
        </ClientSettings>
        <MasterTableView DataKeyNames="ID" EditMode="EditForms">
            <RowIndicatorColumn>
                <HeaderStyle Width="20px"></HeaderStyle>
            </RowIndicatorColumn>
            <ExpandCollapseColumn>
                <HeaderStyle Width="20px"></HeaderStyle>
            </ExpandCollapseColumn>
            <CommandItemSettings ExportToPdfText="Export to Pdf"></CommandItemSettings>
            <Columns>
                <telerik:GridClientSelectColumn UniqueName="ClientSelectColumn" />
                <telerik:GridBoundColumn DataField="ID" HeaderText="ID" UniqueName="ID" Visible="True"
                    ReadOnly="true" FilterControlWidth="30px" HeaderStyle-Width="50px">
<HeaderStyle Width="50px"></HeaderStyle>
                </telerik:GridBoundColumn>
                <telerik:GridDateTimeColumn DataField="Date" DataType="System.DateTime" HeaderText="Date"
                    UniqueName="DateFrom" ReadOnly="true" DataFormatString="{0:dd/MM/yyyy}" AllowFiltering="false"
                    HeaderStyle-Width="75px">
                    <HeaderStyle Width="75px"></HeaderStyle>
                </telerik:GridDateTimeColumn>
                <telerik:GridBoundColumn DataField="User.UserName" HeaderText="User" UniqueName="User"
                    ReadOnly="true">
                </telerik:GridBoundColumn>
                <telerik:GridNumericColumn UniqueName="Duration" HeaderText="Duration (Hrs)" DataType="System.Double"
                    DataField="Duration" FilterControlWidth="50px">
                    <HeaderStyle Width="80px"></HeaderStyle>
                    <ItemStyle HorizontalAlign="Right" />
                </telerik:GridNumericColumn>
                <telerik:GridBoundColumn DataField="ShortDescription" HeaderText="Description" UniqueName="Description">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="DocketNo" HeaderText="Docket No" UniqueName="DocketNo"
                    ReadOnly="true" FilterControlWidth="50px" HeaderStyle-Width="70px">
<HeaderStyle Width="70px"></HeaderStyle>
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="FileCode" HeaderText="FileCode Name" UniqueName="FileCode"
                    HeaderStyle-Width="100px" FilterControlWidth="60px">
<HeaderStyle Width="100px"></HeaderStyle>
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="FileCodeID" HeaderText="FileCode ID" UniqueName="FileCodeID"
                    Visible="false">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="CostCenter" HeaderText="Cost Center" UniqueName="CostCenter"
                    HeaderStyle-Width="70px" FilterControlWidth="40px">
<HeaderStyle Width="70px"></HeaderStyle>
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="CostCenterID" HeaderText="Cost Center ID" UniqueName="CostCenterID"
                    Visible="false">
                </telerik:GridBoundColumn>
                <telerik:GridBoundColumn DataField="CompanyID" HeaderText="Company ID" UniqueName="CompanyID"
                    Visible="false">
                </telerik:GridBoundColumn>
                <telerik:GridCheckBoxColumn DataField="IsOvertime" DataType="System.Boolean" HeaderText="Overtime"
                    UniqueName="Overtime" ReadOnly="true">
                </telerik:GridCheckBoxColumn>
            </Columns>
            <EditFormSettings UserControlName="UserControls/TimesheetEdit.ascx" EditFormType="WebUserControl">
                <EditColumn FilterControlAltText="Filter EditCommandColumn column">
                </EditColumn>
            </EditFormSettings>
        </MasterTableView>
        <HeaderStyle HorizontalAlign="Center"></HeaderStyle>
        <PagerStyle Mode="NumericPages" VerticalAlign="Bottom" />
        <FilterMenu EnableImageSprites="False">
        </FilterMenu>
        <HeaderContextMenu CssClass="GridContextMenu GridContextMenu_Windows7">
        </HeaderContextMenu>
    </telerik:RadGrid>


Thanks in advance.

Daryl
Pavlina
Telerik team
 answered on 21 Mar 2011
1 answer
129 views
Hello Telerik ,
i have problem with radajaxmanager,i have 2 radgrids in my page,while i am clicking the first radgrid itemcommand event ,i need to bind second radgrid ,i am using radajaxmanager,because of this i am unable to bind data to the second radgrid.when i removed radajaxmanager i am able to bind,but i need that radajaxmanager to open radwindow.i did my binding to first radgrid with the example of "http://demos.telerik.com/aspnet-ajax/controls/examples/integration/grwindow/defauidandltcs.aspx?product=window".please give me some idea.
        
Pavlina
Telerik team
 answered on 21 Mar 2011
2 answers
100 views

Hello,

I have a problem with radwindow control (using IE8).

I'm using scriptmanager and updatepanel controls in my application (please view the attached sample in http://www.telerik.com/account/support-tickets/view-ticket.aspx?threadid=400607).
The webpage is saving history points with no problems, until I show the radwindow control. If I open the radwindow then the history points are deleted.
Note: I checked this issue in IE7, it is working with no problems. The problem is in IE8.

I checked with microsoft support this issue. But they told me that it is related some how to the radwindow itself. So plaese, I need your help.

Please look at the following situations:

Good situation:
1) click "Main Attractions" checkbox
2) click "Shopping & Fashion" checkbox
3) Click "Tel Aviv" Linkbutton.
4) Click "Netanya" Linkbutton.
5) Click "Eilat" Linkbutton.
6) Cick the browser back button few times (THIS SHOWS YOU THAT THE HISTORY POINTS ARE SAVED AND USED)
 
Bad Situation 1:
1) click "Main Attractions" checkbox
2) click "Shopping & Fashion" checkbox
3) Click "Tel Aviv" Linkbutton.
4) Click "Netanya" Linkbutton.
5) Click "Eilat" Linkbutton.
6) Click "Full Screen"  button in order to open the map in full screen mode (Radwindow).
7) Cick the browser back button few times (THIS SHOWS YOU THAT THE HISTORY POINTS ARE DELETED)


Bad Situation 2:
1) click "Main Attractions" checkbox
2) click "Shopping & Fashion" checkbox
3) Click "Tel Aviv" Linkbutton.
4) Click "Netanya" Linkbutton.
5) Click "Eilat" Linkbutton.
6) Click the "About" linkbutton and then click close.
7) Cick the browser back button few times (THIS SHOWS YOU THAT THE HISTORY POINTS ARE DELETED)

So, I need to enable the user to go back and forward using the browser buttons even after opeining the radwindow.

Please, I need your help in order to solve this issue.
This issue make problem for me with my client.
It is appricited to send me the modified code.

Regards,
Bader

Bader
Top achievements
Rank 1
 answered on 21 Mar 2011
3 answers
99 views

UseStaticHeaders

 

is working very fine, but when I set the direction of the grid to RTL it gave me an error in graphics because the empty part (above the scroller) in the header is still be drawing in the right side, which causes a displacement in the grid columns.
Could you please help in?

Pavlina
Telerik team
 answered on 21 Mar 2011
2 answers
183 views
Hi,

I have figured out how to use the client-side ajaxRequestWithTarget method of the RadAjaxManager on a single page. But it all goes a bit pear-shaped when I try to do so on a page that has a Master page.

I placed a RadAjaxManagerProxy in the Master page. My first question is, which file do I place the event handler RadAjaxManager1_AjaxRequest in? The CodeFile of the Master page (a user control) or the CodeFile of the aspx page?

I tried it in both places, and the breakpoint which I put in both places was not hit.

The javascript function which I used to initiate the request was fired by the OnClientSelectedIndexChanged event of a RadComboBox control:
<telerik:RadCodeBlock ID="RadCodeBlock" runat="server">
 
    <script type="text/javascript">
        function InitiateAsyncRequestByCombo(sender, eventArgs) {
            var ajaxManager = $find("<%= RadAjaxManager.GetCurrent(this.Page).ClientID %>");
            ajaxManager.ajaxRequestWithTarget("<%= FilterRadComboBox.UniqueID %>", sender.get_selectedItem().get_value());
            return false;
        }
    </script>   
     
</telerik:RadCodeBlock>

Is this something which cannot be done when the RadAjaxManager is on a Master page and the other controls are on a ContentPage?
David
Top achievements
Rank 1
 answered on 21 Mar 2011
2 answers
53 views
I have a grid that is wider than the page. It scrolls fine, but the bottom part of the data border get's cut off where the page ends in FF. I have screen shots below.

http://www.intellicominc.com/temp/first.png
http://www.intellicominc.com/temp/second.png

Here is my master page
<%@ Master Language="VB" CodeFile="Main.master.vb" Inherits="Main" %>


<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <asp:ContentPlaceHolder ID="head" runat="server">
    </asp:ContentPlaceHolder>
    <link rel="Stylesheet" type="text/css" href="Main.css" />
</head>
<body>
    <form id="form1" runat="server">
    <div id="header">
        <a href="~/admin/Default.aspx" runat="server">
            <img src="~/images/logo.jpg" style="border: none;" runat="server" /></a>
        <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        </telerik:RadScriptManager>
        <div style="float: right; right: 20px; top: 10px; position: absolute;">
            <asp:LoginStatus runat="server"></asp:LoginStatus>
        </div>
    </div>
    <div id="Main">
        <telerik:RadSplitter ID="RadSplitter1" runat="server" Orientation="Vertical" Width="100%"
            LiveResize="true" Height="520px">
            <telerik:RadPane ID="LeftRadPane1" runat="server" Width="220px" Scrolling="None"
                BorderStyle="None" BorderSize="0">
                <telerik:RadSplitter ID="radsplitter2" runat="server" Orientation="Horizontal" LiveResize="true">
                    <telerik:RadPane ID="RadPane2" runat="server" Width="220px" Scrolling="None" BorderStyle="None"
                        bordersize="0">
                        <telerik:RadPanelBar runat="server" ID="RadPanelBar1" ExpandMode="FullExpandedItem" Height="100%">
                            <Items>
                                <telerik:RadPanelItem Text="Customers" Expanded="True">
                                    <Items>
                                        <telerik:RadPanelItem Text="Add Customer" NavigateUrl="~/Customers/AddCustomer.aspx" />
                                        <telerik:RadPanelItem Text="Customer List" NavigateUrl="~/Customers/CustomerList.aspx" />
                                    </Items>
                                </telerik:RadPanelItem>
                                <telerik:RadPanelItem Text="Calendar">
                                    <Items>
                                        <telerik:RadPanelItem>
                                            <ItemTemplate>
                                                <telerik:RadCalendar runat="server" ID="Calendar1" Style="margin: 6px auto 0" />
                                            </ItemTemplate>
                                        </telerik:RadPanelItem>
                                    </Items>
                                </telerik:RadPanelItem>
                                <telerik:RadPanelItem Text="Contacts">
                                    <Items>
                                        <telerik:RadPanelItem ImageUrl="Img/contactsItems.gif" Text="My Contacts" />
                                        <telerik:RadPanelItem ImageUrl="Img/contactsItems.gif" Text="Address Cards" />
                                        <telerik:RadPanelItem ImageUrl="Img/contactsItems.gif" Text="Phone List" />
                                        <telerik:RadPanelItem ImageUrl="Img/contactsItems.gif" Text="Shared Contacts" />
                                    </Items>
                                </telerik:RadPanelItem>
                                <telerik:RadPanelItem Text="Tasks">
                                    <Items>
                                        <telerik:RadPanelItem ImageUrl="Img/tasksItems.gif" Text="My Tasks" />
                                        <telerik:RadPanelItem ImageUrl="Img/tasksItems.gif" Text="Shared Tasks" />
                                        <telerik:RadPanelItem ImageUrl="Img/tasksItems.gif" Text="Active Tasks" />
                                        <telerik:RadPanelItem ImageUrl="Img/tasksItems.gif" Text="Completed Tasks" />
                                    </Items>
                                </telerik:RadPanelItem>
                                <telerik:RadPanelItem Text="Notes">
                                    <Items>
                                        <telerik:RadPanelItem ImageUrl="Img/notesItems.gif" Text="My Notes" />
                                        <telerik:RadPanelItem ImageUrl="Img/notesItems.gif" Text="Notes List" />
                                        <telerik:RadPanelItem ImageUrl="Img/notesItems.gif" Text="Shared Notes" />
                                        <telerik:RadPanelItem ImageUrl="Img/notesItems.gif" Text="Archive" />
                                    </Items>
                                </telerik:RadPanelItem>
                            </Items>
                        </telerik:RadPanelBar>
                    </telerik:RadPane>
                </telerik:RadSplitter>
            </telerik:RadPane>
            <telerik:RadSplitBar runat="server" ID="RadSplitBar2" CollapseMode="Forward" EnableResize="true"
                ForeColor='Green' />
            <telerik:RadPane ID="RightRadPane1" runat="server" CssClass="RightPanelPadding" Scrolling="Both"
                BorderStyle="None" BorderSize="0">
                
                <asp:ContentPlaceHolder ID="mainContentPlaceHolder" runat="server">
                </asp:ContentPlaceHolder>
                
            </telerik:RadPane>
        </telerik:RadSplitter>
    </div>
    </form>
</body>
</html>

Here is the css
body {


}
#header{
    width: 100%;
    height: 114px;
}
.leftMenu{
    width: 280px;
    height: 100%;
}
#main{
    height: 800px;
}
.inputTableWidth{
    width: 375px;
}
.rightPanelPadding{
    margin-top: 10px;
    margin-left: 10px;
    width: 100%;
}

And here is the page in question, just databind the grid with enough columns to make it scroll
<%@ Page Title="" Language="VB" MasterPageFile="~/Main.master" AutoEventWireup="false" CodeFile="CustomerList.aspx.vb" Inherits="Customers_CustomerList" %>


<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>


<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="mainContentPlaceHolder" Runat="Server">
     <telerik:RadGrid ID="RadGrid1" runat="server"
            GridLines="None" AllowPaging="True" AllowFilteringByColumn="True" 
            AllowSorting="True" AutoGenerateColumns="false">
            <MasterTableView DataKeyNames="CustomerId" AutoGenerateColumns="false">
                <RowIndicatorColumn>
                    <HeaderStyle Width="20px"></HeaderStyle>
                </RowIndicatorColumn>
                <ExpandCollapseColumn>
                    <HeaderStyle Width="20px"></HeaderStyle>
                </ExpandCollapseColumn>
                <Columns>
                    <telerik:GridBoundColumn DataField="FirstName" HeaderText="FirstName" SortExpression="FirstName"
                        UniqueName="FirstName">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="LastName" HeaderText="LastName" SortExpression="LastName"
                        UniqueName="LastName">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Business Name" HeaderText="Business Name" SortExpression="Business Name"
                        UniqueName="Business Name">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="State" HeaderText="State" SortExpression="State"
                        UniqueName="State">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Zip" HeaderText="Zip" SortExpression="Zip" UniqueName="Zip">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Address" HeaderText="Address" SortExpression="Address"
                        UniqueName="Address">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="City" HeaderText="City" SortExpression="City"
                        UniqueName="City">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Phone" HeaderText="Phone" SortExpression="Phone"
                        UniqueName="Phone">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Fax" HeaderText="Fax" SortExpression="Fax" UniqueName="Fax">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Email" HeaderText="Email" SortExpression="Email"
                        UniqueName="Email">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="CellPhone" HeaderText="CellPhone" SortExpression="CellPhone"
                        UniqueName="CellPhone">
                    </telerik:GridBoundColumn>
                    <telerik:GridBoundColumn DataField="Edit" HeaderText="<a href='test'>test</a>" >
                    </telerik:GridBoundColumn>
                </Columns>
            </MasterTableView>
        </telerik:RadGrid>
</asp:Content>





Web Services
Top achievements
Rank 2
 answered on 21 Mar 2011
7 answers
284 views
Hi,
            I have enable  <ClientSettings>
                    <Selecting AllowRowSelect="true" />
                </ClientSettings>

Now when I select any row in the Grid. There will a check box in the Grid ItemTemplate. that should be checked
and unchecked. please help me on this issue.

Sebastian
Telerik team
 answered on 21 Mar 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?