Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
203 views
Hello all
I have some telerik radgrid and it has a column grouping , but when I try  to scroll the grid I get untidy columns in its order as shown in the attached image
my code in aspx file appears as the following:

                    <telerik:RadGrid AllowPaging="True" BorderStyle="Dashed" BorderColor="red" GridLines="Both" AllowSorting="True" Style="table-layout: auto !important;" AutoGenerateColumns="False" ID="RadGrid_ProductionOrderItems" AllowAutomaticDeletes="True" Width="100%"
                        AllowMultiRowSelection="True" EnableAJAX="True" PageSize="10" runat="server" Skin="Default" AllowAutomaticUpdates="True" OnBatchEditCommand="RadGrid_ProductionOrderItems_BatchEditCommand" OnItemDataBound="RadGrid_ProductionOrderItems_ItemDataBound">
                        <SortingSettings SortedBackColor="#FFF6D6" EnableSkinSortStyles="false" />
                        <ClientSettings AllowKeyboardNavigation="True">
                            <ClientEvents OnRowClick="RowClick" OnBatchEditOpened="BatchEditSetCellValue_Item" />
                            <Selecting AllowRowSelect="true" />
                            <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="true" FrozenColumnsCount="6" />
                            <KeyboardNavigationSettings EnableKeyboardShortcuts="True" AllowActiveRowCycle="true" />
                        </ClientSettings>
                        <PagerStyle Mode="NextPrevAndNumeric" />
                        <MasterTableView CommandItemDisplay="Top" Style="table-layout: auto !important;" AutoGenerateColumns="False" AllowMultiColumnSorting="true"
                            EditMode="Batch" DataKeyNames="Item_Id" ClientDataKeyNames="Item_Id" ShowFooter="True" Width="100%" TableLayout="Fixed" >
                            <BatchEditingSettings EditType="Cell" OpenEditingEvent="Click" />
                            <CommandItemSettings ShowAddNewRecordButton="False" ShowSaveChangesButton="False" ShowCancelChangesButton="False" />
                            <PagerStyle AlwaysVisible="true" />
                            <FooterStyle CssClass="RadGridFooterStyle" />
                            <ColumnGroups>
                                <telerik:GridColumnGroup HeaderText="Item Order" Name="ItemOrder" HeaderStyle-HorizontalAlign="Center">
                                   <%-- <HeaderStyle CssClass="testrightTH"></HeaderStyle>--%>
                                </telerik:GridColumnGroup>
                                <telerik:GridColumnGroup HeaderText="Production Data" Name="ProductionData" HeaderStyle-HorizontalAlign="Center">
                                    <%--<HeaderStyle CssClass="testleftTH"></HeaderStyle>--%>

                                </telerik:GridColumnGroup>
                            </ColumnGroups>
                            <Columns>
                                <telerik:GridTemplateColumn ColumnGroupName="ItemOrder" HeaderText="Code"  ItemStyle-Width="150px" UniqueName="Code" DataField="Code" EditFormColumnIndex="1">
                                    <ItemTemplate>
                                        <%# Eval("Code") %>
                                    </ItemTemplate>
                                    <EditItemTemplate>
                                        <div class="col-sm-12" style="padding-left: 0px; padding-right: 0px">
                                            <asp:TextBox ID="txt_Code" CssClass="input-sm form-control" Enabled="False" runat="server" />
                                            <asp:LinkButton ID="LinkButton1" CssClass="btn-search-warp" Style="margin-top: -33px; right: 4px;" runat="server" OnClientClick="openWinNavigateUrlItem(); return false;">
                                                <i id="I1" class="fa fa-search" runat="server" />
                                            </asp:LinkButton>
                                        </div>
                                    </EditItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDbold" />
                                    <HeaderStyle Width="150px" CssClass="defaultTH  defaultTDbold" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridBoundColumn ColumnGroupName="ItemOrder" DataField="Name" HeaderText="Name"   ItemStyle-Width="75px" UniqueName="Name" ReadOnly="True" EditFormColumnIndex="2">
                                    <ItemStyle CssClass="defaultTD defaultTDbold" />
                                    <HeaderStyle Width="75px" CssClass="defaultTH  defaultTDbold" />
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn ColumnGroupName="ItemOrder" DataField="Color_Name" HeaderText="Color" ItemStyle-Width="70px" UniqueName="Color_Name" ReadOnly="True" EditFormColumnIndex="3">
                                    <ItemStyle CssClass="defaultTD defaultTDbold" />
                                    <HeaderStyle Width="70px" CssClass="defaultTH  defaultTDbold" />
                                </telerik:GridBoundColumn>
                                <telerik:GridBoundColumn ColumnGroupName="ItemOrder" DataField="Width" HeaderText="Width"  ItemStyle-Width="50px" UniqueName="Width" ReadOnly="True" EditFormColumnIndex="4">
                                    <ItemStyle CssClass="defaultTD defaultTDbold" />
                                    <HeaderStyle Width="50px" CssClass="defaultTH  defaultTDbold" />
                                </telerik:GridBoundColumn>

                                <telerik:GridBoundColumn ColumnGroupName="ItemOrder" DataField="Treatment" HeaderText="Treatment" SortExpression="Treatment" HeaderStyle-Width="" ItemStyle-Width="75px"
                                    UniqueName="Treatment" EditFormColumnIndex="5">
                                    <ItemStyle CssClass="defaultTD defaultTDbold" />
                                    <HeaderStyle Width="75px" CssClass="defaultTH  defaultTDbold" />
                                </telerik:GridBoundColumn>


                                <telerik:GridNumericColumn ColumnGroupName="ItemOrder" DataField="Quantity" HeaderText="Quantity" SortExpression="Quantity"   ItemStyle-Width="61px"
                                    UniqueName="Quantity" FooterText="Total : " Aggregate="Sum" EditFormColumnIndex="6">
                                    <ItemStyle CssClass=" testright defaultTDbold"></ItemStyle>
                                    <HeaderStyle Width="60px" CssClass=" testrightTH defaultTDbold"></HeaderStyle>

                                </telerik:GridNumericColumn>

                                <telerik:GridNumericColumn ColumnGroupName="ProductionData" DataField="ProQuantity" HeaderText="Pro Quantity" SortExpression="ProQuantity"  ItemStyle-Width="85px"
                                    UniqueName="ProQuantity" FooterText="Total : " Aggregate="Sum">
                                    <ItemStyle CssClass="testleft defaultTDnormal"></ItemStyle>
                                    <HeaderStyle Width="85px" CssClass="testleftTH defaultTDnormal"></HeaderStyle>

                                </telerik:GridNumericColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Open Card" UniqueName="OpenCard"  ItemStyle-Width="100px" ReadOnly="True">
                                    <ItemTemplate>
                                        <asp:Label runat="server" Text='<%# Convert.ToInt32(Eval("OpenCard")) == 0?"Not Opened":Convert.ToInt32(Eval("OpenCard")) == 1?"Draft":"Original" %>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Machine Group"  ItemStyle-Width="100px" UniqueName="MachineGroup_Name" DataField="MachineGroup_Name">
                                    <ItemTemplate>
                                        <%# Eval("MachineGroup_Name") %>
                                    </ItemTemplate>
                                    <EditItemTemplate> <%--Width="80px" --%>
                                        <telerik:RadDropDownList runat="server" ID="ddl_MachineGroup" DataSourceID="ODS_MachineGroup" DataValueField="ID" DataTextField="Name" />
                                    </EditItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridNumericColumn ColumnGroupName="ProductionData" DataField="ProDays" HeaderText="ProDays" SortExpression="ProDays"  ItemStyle-Width="60px"
                                    UniqueName="ProDays" FooterText="Total : " Aggregate="Sum">
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="60px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridNumericColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Fax Order" ItemStyle-Width="100px" UniqueName="Fax_Code" DataField="Fax_Code">
                                    <ItemTemplate>
                                        <%# Eval("Fax_Code") %>
                                    </ItemTemplate>
                                    <EditItemTemplate><%--Width="100px"--%>
                                        <telerik:RadDropDownList  runat="server" ID="ddl_FaxOrder" DataSourceID="ODS_FaxOrder" DataValueField="ID" DataTextField="Fax_Code" />
                                    </EditItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridDateTimeColumn ColumnGroupName="ProductionData" UniqueName="PlanningDate" PickerType="DatePicker" HeaderText="Planning Date" ItemStyle-Width="175px"
                                    DataField="PlanningDate" DataFormatString="{0:MM/yyyy}" Reorderable="True">
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="175px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridDateTimeColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Yarn Status" UniqueName="YarnStatusId" ItemStyle-Width="100px">

                                    <EditItemTemplate>
                                        <div style="padding: 2px 0 3px 0px; position: relative; right: 7px; top: -4px; width: 100px; '<%# ((float.Parse(Eval("YarnStatusPercetage").ToString()) < 50)?"background: red;": ((float.Parse(XPath("YarnStatusPercetage").ToString()) > 50&&float.Parse(XPath("YarnStatusPercetage").ToString())<100)?"background: orange;":"background: green;"))%>">
                                            <asp:CheckBox ID="CheckBox2_YarnStatusId" Enabled="False" runat="server" Checked='<%#  Convert.ToInt32(Eval("YarnStatusId")) == 1 %>' />
                                            <asp:LinkButton ID="lbtn_YarnWarpWaftStatus" Style="position: relative; right: -25px; top: 12px;"
                                                CssClass="btn-search-warp" runat="server" OnClientClick="openWinNavigateUrlYarnWarpWaftStatus(); return false;">
                                                <i id="I2" class="fa fa-search" runat="server" />
                                            </asp:LinkButton>
                                        </div>
                                    </EditItemTemplate>
                                    <ItemTemplate>
                                        <div style='<%# ((float.Parse(Eval("YarnStatusPercetage").ToString()) < 50)?"background: red;": ((float.Parse(Eval("YarnStatusPercetage").ToString()) > 50&&float.Parse(Eval("YarnStatusPercetage").ToString())<100)?"background: orange;":"background: green;"))+"padding: 2px 0 3px 0px;position: relative;right: 7px;top: -4px;width: 100px;" %>'>
                                            <asp:CheckBox ID="CheckBox1_YarnStatusId" Enabled="False" runat="server" Checked='<%# Convert.ToInt32(Eval("YarnStatusId")) == 1 %>' />
                                        </div>
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                              <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Warp Status" UniqueName="WarpStatusId" HeaderStyle-Width="100px" ItemStyle-Width="100px">
                                    <EditItemTemplate>
                                        <span>
                                        <asp:CheckBox ID="CheckBox2_WarpStatusId" runat="server" Checked='<%#  Convert.ToInt32(Eval("WarpStatusId")) == 1 %>' CssClass='<%# Convert.ToInt32(Eval("WarpStatusId")) == 1 ?  "warpTrue" :"warpFalse"  %>' onclick="javascript: CheckedChange(this);" />
                                            </span>
                                    </EditItemTemplate>
                                    <ItemTemplate>
                                        <asp:CheckBox ID="CheckBox1_WarpStatusId" Enabled="False" runat="server" Checked='<%# Convert.ToInt32(Eval("WarpStatusId")) == 1 %>'  CssClass='<%# Convert.ToInt32(Eval("WarpStatusId")) == 1 ?  "warpTrue" :"warpFalse"  %>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>

                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Pro Status" UniqueName="ProStatusId" HeaderStyle-Width="100px" ItemStyle-Width="100px">
                                    <EditItemTemplate>
                                        <asp:CheckBox ID="CheckBox2_ProStatusId" Enabled='<%# Eval("CurrentClose") %>' runat="server" Checked='<%#  Convert.ToInt32(Eval("ProStatusId")) == 1 %>' />
                                    </EditItemTemplate>
                                    <ItemTemplate>
                                        <asp:CheckBox ID="CheckBox1_ProStatusId" Enabled="False" runat="server" Checked='<%# Convert.ToInt32(Eval("ProStatusId")) == 1 %>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridCheckBoxColumn ColumnGroupName="ProductionData" DataField="CurrentClose" HeaderText="Close" SortExpression="CurrentClose" UniqueName="CurrentClose" HeaderStyle-Width="100px" ItemStyle-Width="100px">
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridCheckBoxColumn>
                               <%-- //////////////////////////////////////////////////////////////////////////////////////////////////////////////// --%>
                              
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Close Quantity" UniqueName="CloseQty"  ItemStyle-Width="100px" ReadOnly="True">
                                    <ItemTemplate>
                                        <asp:Label ID="Label1" runat="server" Text='<%# Eval("CloseQty")%>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Roll Status" UniqueName="RollStatus"   ItemStyle-Width="100px">
                                    <EditItemTemplate>
                                        <asp:CheckBox ID="CheckBox2_RollStatus" runat="server" Checked='<%#  Convert.ToInt32(Eval("RollStatus")) == 1 %>' />
                                    </EditItemTemplate>
                                    <ItemTemplate>
                                        <asp:CheckBox ID="CheckBox1_RollStatus" Enabled="False" runat="server" Checked='<%# Convert.ToInt32(Eval("RollStatus")) == 1 %>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Roll Quantity" UniqueName="RollQty"  ItemStyle-Width="100px" ReadOnly="True">
                                    <ItemTemplate>
                                        <asp:Label runat="server" Text='<%# Eval("RollQty")%>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridTemplateColumn ColumnGroupName="ProductionData" HeaderText="Lab Status" UniqueName="LabStatus" ItemStyle-Width="100px">
                                    <EditItemTemplate>
                                        <asp:CheckBox ID="CheckBox2_LabStatus" runat="server" Checked='<%#  Convert.ToInt32(Eval("LabStatus")) == 1 %>' />
                                    </EditItemTemplate>
                                    <ItemTemplate>
                                        <asp:CheckBox ID="CheckBox1_LabStatus" Enabled="False" runat="server" Checked='<%# Convert.ToInt32(Eval("LabStatus")) == 1 %>' />
                                    </ItemTemplate>
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="100px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridTemplateColumn>
                                <telerik:GridDateTimeColumn ColumnGroupName="ProductionData" UniqueName="DeliverDate" PickerType="DateTimePicker" HeaderText="Delivery Date"  ItemStyle-Width="150px"
                                    DataField="DeliverDate" DataFormatString="{0:MM/dd/yyyy hh:mm:ss tt}" Reorderable="True">
                                    <ItemStyle CssClass="defaultTD defaultTDnormal" />
                                    <HeaderStyle Width="150px" CssClass="defaultTH  defaultTDnormal" />
                                </telerik:GridDateTimeColumn>
                               
                            </Columns>
                        </MasterTableView>
                    </telerik:RadGrid>

please if any body can help me or tell me about some URL may help me in solve this issue please reply me

Regards
Mostafa
Pavlina
Telerik team
 answered on 10 Jul 2014
3 answers
193 views
We know that this error means that RadGrid is unable to find the aforementioned datakey in your datasource. and we need to correct the datasource. But somehow if this error still comes then is there a way to handle it generously and show some user friendly message by catching this error.

Which event we can catch this error in code behind as we need to catch when this type of error comes and show some friendly message like "System error occured"

Please help
Radoslav
Telerik team
 answered on 10 Jul 2014
4 answers
171 views
Hi,

I have created some ComboBox in an app.

It works perfectly in Firefox, but not in Chrome.

Have attached the image.

Please let me know if any solution for this.

-Anto
Dimitar Terziev
Telerik team
 answered on 10 Jul 2014
1 answer
102 views
I need suggestions to improve speed and usability. I have a RadComboBox with over 700 items. The user needs to be able to select multiple items from the list, so I have checkboxes turned on. However, the combination of checkboxes and a large number of items makes the combobox open and close very slowly. I was told that the usability is not acceptable for the users and I need to make it work faster. I have 5 of these long checkbox lists on the page.
Dimitar Terziev
Telerik team
 answered on 10 Jul 2014
1 answer
182 views
Hi Telerik,

I need copy the raw table from MS Word to Editor, I've use "Non SupressClean Message" but It still clean my table in the content. Now I want to copy all my content from word with no formating

Plz help, Thanks
Ianko
Telerik team
 answered on 10 Jul 2014
1 answer
193 views
Example not work http://www.telerik.com/help/aspnet-ajax/page-layout-sticky-footer-header.html
Footer stick to bottom of "Article 1(2)"
IE 11, Chrome 35, Opera 22
Boyan Dimitrov
Telerik team
 answered on 10 Jul 2014
1 answer
78 views
Hi ..
I have a button which Creates a pdf and after that i need to refresh the radgrid .. I call the same Search button but the radgrid remains the same and not being
refreshed. Any idea how this event can be handled ?
Thanks in advance
Spiros
Viktor Tachev
Telerik team
 answered on 10 Jul 2014
2 answers
124 views
Dear Telerik,

Is there a way to create calculated item programmatically?

The situation is that I have a series of e.GroupName.ToString() calculation cases in the ItemNeedCalculation event, however, being unable to access hide/show visibility of one of the fields, I am thinking of using a check box to generate such calculated item programmatically. Or else is there any better solution to my original purposes to hide calculated item?

Sorry for multiple questions, but I couldn't find enough information regarding calculated item. Much Appreciated!

Best regards.

Kostadin
Telerik team
 answered on 10 Jul 2014
5 answers
348 views
Hi!

I'm using RadProgressManager and RadProgressArea to monitor a custom progress in the following scenario:

  1. The user clicks "Create" button
  2. At server-side, X items are being added to a Zip-file. For each item, the custom progress is updated.
  3. When the Zip-file is created, it is written to the Response-stream.
  4. The Zip-file is available for download.

If the user would click the "Create" button again, the progress area won't display. Is it possible to "reset" the RadProgressManager in any way after it has finished (without having to redirect to the same page again)?
Hristo Valyavicharski
Telerik team
 answered on 10 Jul 2014
1 answer
232 views
Hi,

I want to show file filter for images , i have put the code at my design page

Telerik.Web.UI.RadAsyncUpload.Modules.FileApi.isAvailable = function () { return false; };
Telerik.Web.UI.RadAsyncUpload.Modules.IFrame.isAvailable = function () { return false; };

This code is not working fine when first time the page is loaded and then i click browse,but when i perform any operation like editing a radgrid or some other operation and then i click browse then its working properly.

Hereby i attached 2 files First Time and Second Time .In FirstTime Image it does not show anything and in SecondTime  it shows Filter Icon.


Plz Suggest
Hristo Valyavicharski
Telerik team
 answered on 10 Jul 2014
Narrow your results
Selected tags
Tags
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?