Telerik Forums
UI for ASP.NET AJAX Forum
5 answers
733 views
hey,

I am using a radgrid which is empty consists grid item templates like-
<telerik:RadGrid ID="RadGrid1" runat="server" GridLines="None"           OnItemDataBound="RadGrid1_ItemDataBound" OnItemCreated="RadGrid1_ItemCreated" OnColumnCreated="RadGrid1_ColumnCreated"AllowAutomaticInserts="true" OnNeedDataSource="RadGrid1_NeedDataSource" Skin="Office2007"AutoGenerateColumns="true">
                    <MasterTableView EditMode="InPlace" EnableNoRecordsTemplate="true" EnableViewState="true">
                        <RowIndicatorColumn>
                            <HeaderStyle Width="20px" />
                        </RowIndicatorColumn>
                        <ExpandCollapseColumn>
                            <HeaderStyle Width="20px" />
                        </ExpandCollapseColumn>
                        <Columns>
                            <telerik:GridTemplateColumn HeaderText="Items" UniqueName="ItemColumn">
                                <ItemTemplate>
                                    <asp:Label ID="lblItemName" runat="server" />
                                </ItemTemplate>
                                <EditItemTemplate>
                                    <asp:DropDownList ID="ddlItems" runat="server" DataSourceID="SqlDataSource1" />
                                </EditItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn HeaderText="Rate" UniqueName="RateColumn">
                                <ItemTemplate>
                                    <asp:Label ID="lblRate" runat="server" />
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn HeaderText="Quantity" UniqueName="QuantityColumn">
                                <ItemTemplate>
                                    <asp:Label ID="lblQuantity" runat="server" />
                                </ItemTemplate>
                                <EditItemTemplate>
                                    <telerik:RadTextBox ID="txtQuantity" runat="server" />
                                </EditItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridTemplateColumn HeaderText="Amount" UniqueName="AmountColumn">
                                <ItemTemplate>
                                    <asp:Label ID="lblAmount" runat="server" />
                                </ItemTemplate>
                            </telerik:GridTemplateColumn>
                            <telerik:GridButtonColumn HeaderText="Done" Text="Done" UniqueName="Donecolumn">
                            </telerik:GridButtonColumn>
                        </Columns>
                        <NoRecordsTemplate>
                            There isn't any data.</NoRecordsTemplate>
                    </MasterTableView>
                    <ClientSettings EnablePostBackOnRowClick="true" />
                </telerik:RadGrid>
                <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ChalkHillConnectionString3 %>"
                    SelectCommand="SELECT [ProductName] FROM [tblProducts]"></asp:SqlDataSource>
C# is
protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                //AddValuesToItemsDropdown();
                RadGrid1.Visible = true;
            }
        }
protected void ddlItems_SelectedIndexChanged(object sender, EventArgs e)
        {
            DropDownList ddlItems = (DropDownList)sender;
            GridEditFormItem editItem = (GridEditFormItem)ddlItems.NamingContainer;
            GridDataItem item = (GridDataItem)editItem.ParentItem; // access GridDataItem
            Label lblRate = (Label)item.FindControl("lblRate"); // access Label using DataItem
            if (ddlItems.SelectedIndex > 0)
            {
                DataSet ds = objSQLHelper.GetProductDetails("select * from tblProducts where Pid=" + ddlItems.SelectedValue);
                if (ds != null)
                {
                    lblRate.Text = ds.Tables[0].Rows[0]["Rate"].ToString();
                }
            }
        }
 
        protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e)
        {
            if ((e.Item is GridEditFormItem) && (e.Item.IsInEditMode))
            {
                GridEditFormItem editform = (GridEditFormItem)e.Item;
                e.Item.Edit = true;
                DropDownList ddlItems = (DropDownList)editform.FindControl("ddlItems");
                ddlItems.DataSource = ds;
                ddlItems.DataTextField = "ProductName";
                ddlItems.DataValueField = "Pid";
                ddlItems.DataBind();
            }
        }
        private void RadGrid1_PreRender(object sender, System.EventArgs e)
        {
            if (!IsPostBack)
            {
                foreach (GridItem item in RadGrid1.MasterTableView.Items)
                {
                    if (item is GridEditableItem)
                    {
                        GridEditableItem editableItem = item as GridDataItem;
                        editableItem.Edit = true;
                    }
                }
                RadGrid1.Rebind();
            }
        }
Why is Grid not visible on page load?....
Pavlina
Telerik team
 answered on 22 Mar 2011
1 answer
92 views
Hi
i use the RadScheduler in an new developed web application with customized control skins for the telerik rad controls by myself.
Now i will change the cell height in all views (week view, day view, etc) in css file. I'm looking for some entries in the control-css, but i have not found the right place...

 How can i do that?

I hope anybody can help.

thanks.

René
Princy
Top achievements
Rank 2
 answered on 22 Mar 2011
2 answers
154 views
Hi, I have a treeview as follows:
<telerik:RadTreeView ID="tvCC" Runat="server" CheckBoxes="True" 
        Skin="Vista" TriStateCheckBoxes="True" CheckChildNodes="True" BorderStyle="Solid"
        BorderColor="Black" BorderWidth="1"  Height="350px" Width="400px" >
</telerik:RadTreeView>          

In the code behind I disable a child node of a root node.
This prevents the user from checking or unchecking the specific node.
This is good. However, if I  uncheck or check the parent node the child still get's toggled even though it's disabled.
Anyway to prevent this client side?
Thanks ... Ed
Ed Staffin
Top achievements
Rank 1
 answered on 22 Mar 2011
1 answer
68 views
I am using the Q# 2010 version of RadPanel.
I am using:

.rpItem

{

 

 

border-bottom:solid 2px #8F835E ;

 

 

}


to create a dividing border between panel items.
This works perfectly in IE8 but IE7 ignores any styling applied to this item.
How can I get this to work in IE7?

steve matheson
Kate
Telerik team
 answered on 22 Mar 2011
1 answer
93 views
I would like to centralize all the RadEditor's dictionary at one location instead of off /App_Data in each webapp. 
Each app might have slightly different versions of RadEditor (depends on which hotfix is used).

I'd think this en-US.tdf should be highly compatible but let me know if there is anything to watch out for.
I also assume the custom dictionary will be shared amongst the webapps so as long as the format does not change it should be OK.
Rumen
Telerik team
 answered on 22 Mar 2011
1 answer
399 views
Dear support team,

i have a problem with the text property of the button.
As you can see in my attached image, i have a big text for the button.
The problem is that the space between the text lines, are very big and the text is outside the button.

Is this a bug or i'm doing something wrong?
How can i accomplish normal multiline text in the button?

Thank you in advance for your time.

I use Version Q1 2011 released 03/15/2011

George,
Navarino Technology Department.
Bozhidar
Telerik team
 answered on 22 Mar 2011
1 answer
127 views
Am having a heck of a time figuring this chart stuff out. All I want is a simple horizontal bar graph showing current year and previous year totals. The y axis would be fixed and just have "2011" and "2010" as labels. The x axis would auto scale the totals. And I'd like the totals to appear as text within the bar as well. Can someone please give me an example of this working? Thanks.
Digital Man
Top achievements
Rank 2
 answered on 22 Mar 2011
1 answer
115 views
Hi,

I've been looking at the below demo:
http://demos.telerik.com/aspnet-ajax/fileexplorer/examples/server-sideapi/filtertextbox/defaultcs.aspx

EnableFilterTextBox seems to be missing from my Intellisense, other properties seem to be there. I'm using 2010.3.1317.20 asp.net 4

Thanks
Dobromir
Telerik team
 answered on 22 Mar 2011
0 answers
81 views
i have to problem  when use grid with popupExtender


1- i have ajax popupExtender contain gridview and grid has enabled AllowFilteringByColumn the problem is filtering columnpopup
show behind PeopUpExtender , how can i show filtering popupcolumn usual

2- any postback happen on this  popupExtender its become hide , i need it still show ,i will close it after finish my manipulation


-----
best regards
Abdallah
Top achievements
Rank 1
 asked on 22 Mar 2011
2 answers
252 views
Hi all,

Now i use radgrid to sum up 2 columns value which are Total A and Total B.
How can i pass these value to back end for calculation purpose?

Thank you.

Best regards,
nasri.
Arteta Sam
Top achievements
Rank 1
 answered on 22 Mar 2011
Narrow your results
Selected tags
Tags
+? more
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Shiori
Top achievements
Rank 2
Iron
Tien
Top achievements
Rank 1
Iron
Robert
Top achievements
Rank 1
Rob
Top achievements
Rank 4
Bronze
Bronze
Iron
Geoff
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?