Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
137 views

Hello Team, 

We have a new feature in application where we will have a page with one RadTreeView and two or three RadEditor.

The RadTreeView will be added to display the list of images and user will drag the image and drop to any editor.

As per the demo the one Treeview and one Editor is working okay. But when I add two or more Editor the dropping is not working in all editor. We can drop the image only the last editor.  I also tried to get the destination item (editor or div ) in OnClientNodeDropping event but I did not get the destination item. If we get it when we can add the image in destination item (editor or div ). 

Dear expert, is there anyway to get the Id of destination item in  OnClientNodeDropping event?

Or 

Any solution of this problem problem.

 

Thanks

 

 

 

 

Rumen
Telerik team
 answered on 02 Aug 2017
1 answer
317 views

I don't know how this has been missed in the documentation. Alternatively, it's well hidden in some obscure place. I'm trying to filter a column of a detail table using a static radcombobox. Using the instructions from the "Filter Template" documentation (http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/functionality/filtering/filter-template) I'm not seeing any filtering in action on the detail table. The documentation for "Detail Tables Filtering" is rather useless (http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/functionality/filtering/detail-tables-filtering).

Someone show me where I'm going wrong?

<telerik:RadGrid ID="rgdepots" runat="server"
AutoGenerateColumns="False"
DataSourceID="depots"
AllowFilteringByColumn="True"
AllowSorting="True" Height="900px"
OnItemDataBound="rgdepots_ItemDataBound" EnableLinqExpressions="false">
<GroupingSettings CollapseAllTooltip="Collapse all groups"></GroupingSettings>
<ClientSettings>
<Scrolling AllowScroll="True" UseStaticHeaders="True" />
</ClientSettings>
<MasterTableView DataKeyNames="dID" DataSourceID="depots">
<DetailTables>
<telerik:GridTableView runat="server"
Name="rgIncidents"
AllowAutomaticInserts="true"
AllowAutomaticUpdates="True"
DataKeyNames="iID"
DataSourceID="sql"
EditMode="PopUp"
AutoGenerateColumns="False"
AllowPaging="True"
PageSize="30"
CommandItemDisplay="Top" EditFormSettings-FormMainTableStyle-Width="480px" EditFormSettings-FormStyle-Width="490px">
<EditFormSettings EditFormType="Template">
<FormTemplate>
<table>
<tr><td>Date</td><td><telerik:RadDatePicker ID="iDatePick" runat="server" DbSelectedDate='<%# Bind("iDate") %>'></telerik:RadDatePicker></td></tr>
<tr><td colspan="3" style="text-align: center; border-bottom: 1px solid black;">Forms</td></tr>
<tr style="text-align: center;"><td>Notification</td><td>Accident</td><td>Interview</td></tr>
<tr style="text-align: center;">
<td><telerik:RadCheckBox ID="chkNotification" runat="server" Checked='<%# Bind("iNotificationForm") %>'></telerik:RadCheckBox></td>
<td><telerik:RadCheckBox ID="chkAccident" runat="server" Checked='<%# Bind("iAccidentForm") %>'></telerik:RadCheckBox></td>
<td><telerik:RadCheckBox ID="chkInterview" runat="server" Checked='<%# Bind("iInterviewForm") %>'></telerik:RadCheckBox></td>
</tr>
<tr>
<td>Damage to</td>
<td><telerik:RadCheckBox ID="chkClarkeDamage" runat="server" Text="Clarkes" Checked='<%# Bind("iDamageClarkes") %>'></telerik:RadCheckBox></td>
<td><telerik:RadCheckBox ID="chkOtherDamage" runat="server" Text="3rd Party" Checked='<%# Bind("iDamageThirdParty") %>'></telerik:RadCheckBox></td>
</tr>
<tr>
<td>Repaired by</td>
<td><telerik:RadCheckBox ID="chkClarkeRepair" runat="server" Text="Clarkes" Checked='<%# Bind("iRepairedClarkes") %>'></telerik:RadCheckBox></td>
<td><telerik:RadCheckBox ID="chkOtherRepair" runat="server" Text="3rd Party" Checked='<%# Bind("iRepairedThirdParty") %>'></telerik:RadCheckBox></td>
</tr>
<tr>
<td>Costs</td>
<td>Estimated <telerik:RadTextBox ID="txtEstCost" runat="server" Text='<%# Bind("iEstimate") %>'></telerik:RadTextBox></td>
<td>Actual <telerik:RadTextBox ID="txtActualCost" runat="server" Text='<%# Bind("iClarkesCost") %>'></telerik:RadTextBox></td>
</tr>
<tr><td>Costs Paid</td><td><telerik:RadCheckBox ID="chkPaid" runat="server" Checked='<%# Bind("iNotificationForm") %>'></telerik:RadCheckBox></td></tr>
<tr><td>Location</td><td colspan="2"><telerik:RadTextBox ID="txtLocation" runat="server" Width="320px" Text='<%# Bind("iLocation") %>'></telerik:RadTextBox></td></tr>
<tr><td>Description</td><td colspan="2"><telerik:RadTextBox ID="txtDescription" runat="server" Text='<%# Bind("iDescription") %>' TextMode="MultiLine" Width="320px"></telerik:RadTextBox></td></tr>
<tr>
<td>Driver</td>
<td><telerik:RadCheckBox ID="chkAware" runat="server" Text="Aware" Checked='<%# Bind("iDriverAware") %>'></telerik:RadCheckBox></td>
<td><telerik:RadCheckBox ID="chkFault" runat="server" Text="At Fault" Checked='<%# Bind("iDriverFault") %>'></telerik:RadCheckBox></td>
</tr>
<tr><td>AJG Reference</td><td><telerik:RadTextBox ID="txtAJG" runat="server" Text='<%# Bind("iAJGRef") %>'></telerik:RadTextBox></td></tr>
<tr><td>Depot</td><td><telerik:RadDropDownList ID="txtFK1dID" runat="server" DataSourceID="depots" DataTextField="dCode" DataValueField="dID" SelectedValue='<%# Bind("fk1_dID") %>'></telerik:RadDropDownList></td></tr>
<tr><td><telerik:RadDropDownList ID="rgEddlDriver"runat="server" DataSourceID="sqlDriver" SelectedValue='<%# Bind("fk2_dID") %>' DataTextField="dName" DataValueField="dID" AppendDataBoundItems="true"><Items><telerik:DropDownListItem Value="-1" Text="Select One" /></Items></telerik:RadDropDownList></td>
<td><telerik:RadDropDownList ID="rgEddlCab" runat="server" DataSourceID="sqlCab" SelectedValue='<%# Bind("fk3_cID") %>'  DataTextField="cReg" DataValueField="cID" AppendDataBoundItems="true"><Items><telerik:DropDownListItem Value="-1" Text="Select One" /></Items></telerik:RadDropDownList></td>
<td><telerik:RadDropDownList ID="rgEddlTrailer" runat="server" DataTextField="tRef" DataValueField="tID" AppendDataBoundItems="true"><Items><telerik:DropDownListItem Value="-1" Text="Select One" /></Items></telerik:RadDropDownList></td>
</tr>
<tr>
<td><asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>' runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'></asp:Button></td>
<td> </td>
<td><asp:Button ID="btnCancel" Text="Cancel" runat="server" CausesValidation="False" CommandName="Cancel"></asp:Button></td>
</tr>
</table>
</FormTemplate>
</EditFormSettings>
<ParentTableRelation>
<telerik:GridRelationFields DetailKeyField="fk1_dID" MasterKeyField="dID" />
</ParentTableRelation>
<Columns>
<telerik:GridEditCommandColumn></telerik:GridEditCommandColumn>
<telerik:GridTemplateColumn DataField="iID" DataType="System.Int32" FilterControlAltText="Filter iID column" HeaderText="ID" ReadOnly="True" SortExpression="iID" UniqueName="iID" ForceExtractValue="Always">
<FilterTemplate>
</FilterTemplate>
<ItemTemplate>
<asp:Label ID="lblID" runat="server" Text='<%# string.Format("{0:00#}",Eval("iID")) %>'></asp:Label>/<asp:Label ID="lblDate" runat="server" Text='<%# string.Format("{0:yyyy}",Eval("iDate")) %>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridBoundColumn DataField="iDate" DataType="System.DateTime" FilterControlAltText="Filter iDate column" HeaderText="Date" SortExpression="iDate" UniqueName="iDate" DataFormatString="{0:d}" ForceExtractValue="Always">
<FilterTemplate>
<table>
<tr><td>From</td><td><telerik:RadDateInput ID="fDateFrom" runat="server" Width="80"></telerik:RadDateInput></td></tr>
<tr><td>To</td><td><telerik:RadDateInput ID="fdateTo" runat="server" Width="80"></telerik:RadDateInput></td></tr>
</table>
</FilterTemplate>
</telerik:GridBoundColumn>
<telerik:GridCheckBoxColumn AllowFiltering="false" EnableHeaderContextMenu="false" ReadOnly="false" DataField="iNotificationForm" DataType="System.Boolean" HeaderText="Notification Form" UniqueName="iNotificationForm" ForceExtractValue="Always">
</telerik:GridCheckBoxColumn>
<telerik:GridCheckBoxColumn DataField="iInterviewForm" AllowFiltering="false" DataType="System.Boolean" FilterControlAltText="Filter iInterviewForm column" HeaderText="Interview Form" SortExpression="iInterviewForm" UniqueName="iInterviewForm" ForceExtractValue="Always">
</telerik:GridCheckBoxColumn>
<telerik:GridCheckBoxColumn DataField="iAccidentForm" AllowFiltering="false" DataType="System.Boolean" FilterControlAltText="Filter iAccidentForm column" HeaderText="Accident Form" SortExpression="iAccidentForm" UniqueName="iAccidentForm" ForceExtractValue="Always">
</telerik:GridCheckBoxColumn>
<telerik:GridTemplateColumn HeaderText="Damage" UniqueName="iDamageClarkes" ForceExtractValue="Always">
<FilterTemplate>
<telerik:RadTextBox ID="fTxtDamage" runat="server" Width="60"></telerik:RadTextBox>
</FilterTemplate>
<ItemTemplate>
<asp:Label ID="lblDamage" runat="server" Text='<%# Eval("iDamageClarkes").ToString() == "True" ? Eval("iDamageThirdParty").ToString() == "True" ? "Clarkes, Third Party" : "Clarkes" : Eval("iDamageThirdParty").ToString() == "True" ? "Third Party" : ""%>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn DataField="iRepairedClarkes" DataType="System.Boolean" FilterControlAltText="Filter iRepairedClarkes column" HeaderText="Repaired by" SortExpression="iRepairedClarkes" UniqueName="iRepairedClarkes" ForceExtractValue="Always">
<FilterTemplate>
<telerik:RadTextBox ID="fTxtRepaired" runat="server" Width="60"></telerik:RadTextBox>
</FilterTemplate>
<ItemTemplate>
<asp:Label ID="lblRepairs" runat="server" Text='<%# Eval("iRepairedClarkes").ToString() == "True" ? Eval("iRepairedThirdParty").ToString() == "True" ? "Clarkes, Third Party" : "Clarkes" : Eval("iRepairedThirdParty").ToString() == "True" ? "Third Party" : ""%>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridBoundColumn DataField="iEstimate" DataType="System.Decimal" FilterControlAltText="Filter iEstimate column" HeaderText="Estimate" SortExpression="iEstimate" UniqueName="iEstimate" ForceExtractValue="Always">
<FilterTemplate>
<telerik:RadTextBox ID="fTxtEstimate" runat="server" Width="80"></telerik:RadTextBox>
</FilterTemplate>
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="iClarkesCost" DataType="System.Decimal" FilterControlAltText="Filter iClarkesCost column" HeaderText="ClarkesCost" SortExpression="iClarkesCost" UniqueName="iClarkesCost" ForceExtractValue="Always">
<FilterTemplate>
<telerik:RadTextBox ID="fTxtCost" runat="server" Width="80"></telerik:RadTextBox>
</FilterTemplate>
</telerik:GridBoundColumn>
<telerik:GridCheckBoxColumn AllowFiltering="false" DataField="iPaid" DataType="System.Boolean" FilterControlAltText="Filter iPaid column" HeaderText="Paid" SortExpression="iPaid" UniqueName="iPaid" ForceExtractValue="Always">
</telerik:GridCheckBoxColumn>
<telerik:GridBoundColumn DataField="iDescription" FilterControlAltText="Filter iDescription column" HeaderText="iDescription" SortExpression="Description" UniqueName="iDescription" ForceExtractValue="Always">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="iLocation" FilterControlAltText="Filter iLocation column" HeaderText="iLocation" SortExpression="Location" UniqueName="iLocation" ForceExtractValue="Always">
</telerik:GridBoundColumn>
<telerik:GridTemplateColumn DataField="iDriverAware" HeaderText="Driver" UniqueName="iDriverAware" ForceExtractValue="Always" AllowFiltering="true">
<FilterTemplate>
<telerik:RadComboBox ID="rcbFDriverAware" runat="server" AutoPostBack="true" ShowToggleImage="false" Width="80" OnSelectedIndexChanged="rcbFDriverAware_SelectedIndexChanged">
<Items>
<telerik:RadComboBoxItem Text="Any" />
<telerik:RadComboBoxItem Text="Aware" />
<telerik:RadComboBoxItem Text="At Fault" />
<telerik:RadComboBoxItem Text="Both" />
</Items>
</telerik:RadComboBox>
</FilterTemplate>
<ItemTemplate>
<asp:Label ID="lblDriver" runat="server" Text='<%# Eval("iDriverAware").ToString() == "True" ? Eval("iDriverFault").ToString() == "True" ? "Aware, At Fault" : "Aware" : Eval("iDriverFault").ToString() == "True" ? "At Fault" : ""%>'></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridBoundColumn DataField="iDriverFault" UniqueName="iDriverFault" Display="false" AllowFiltering="true"></telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="iAJGRef" FilterControlAltText="Filter iAJGRef column" HeaderText="AJGRef" SortExpression="iAJGRef" UniqueName="AJGRef" ForceExtractValue="Always">
</telerik:GridBoundColumn>
<telerik:GridTemplateColumn HeaderText="Depot" AllowFiltering="false" ForceExtractValue="Always">
<ItemTemplate>
<telerik:RadDropDownList ID="rgddlDepot" runat="server" DataTextField="dCode" DataValueField="dID" Enabled="false" AppendDataBoundItems="true">
<Items>
<telerik:DropDownListItem Value="-1" Text="Select One" />
</Items>
</telerik:RadDropDownList>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="Driver">
<ItemTemplate>
<telerik:RadDropDownList ID="rgddlDriver" runat="server" DataTextField="dName" DataValueField="dID" Enabled="false" AppendDataBoundItems="true">
<Items>
<telerik:DropDownListItem Value="-1" Text="Select One" />
</Items>
</telerik:RadDropDownList>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="Vehicle">
<ItemTemplate>
<telerik:RadDropDownList ID="rgddlCab" runat="server" DataTextField="cReg" DataValueField="cID" Enabled="false" AppendDataBoundItems="true">
<Items>
<telerik:DropDownListItem Value="-1" Text="Select One" />
</Items>
</telerik:RadDropDownList>
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="Trailer">
<ItemTemplate>
<telerik:RadDropDownList ID="rgddlTrailer" runat="server" DataTextField="tRef" DataValueField="tID" Enabled="false" AppendDataBoundItems="true">
<Items>
<telerik:DropDownListItem Value="-1" Text="Select One" />
</Items>
</telerik:RadDropDownList>
</ItemTemplate>
</telerik:GridTemplateColumn>
</Columns>
<EditFormSettings>
<EditColumn UniqueName="EditCommandColumn1" FilterControlAltText="Filter EditCommandColumn1 column"></EditColumn>
</EditFormSettings>
</telerik:GridTableView>
</DetailTables>
<Columns>
<telerik:GridBoundColumn DataField="dID" DataType="System.Int32" Display="False" FilterControlAltText="Filter dID column" HeaderText="dID" ReadOnly="True" SortExpression="dID" UniqueName="dID">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="dCode" AllowFiltering="false" FilterControlAltText="Filter dCode column" HeaderText="Code" SortExpression="dCode" UniqueName="dCode">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="dName" AllowFiltering="false" FilterControlAltText="Filter dName column" HeaderText="Name" SortExpression="dName" UniqueName="dName">
</telerik:GridBoundColumn>
<telerik:GridBoundColumn DataField="Incidents" AllowFiltering="false" DataType="System.Int32" FilterControlAltText="Filter Incidents column" HeaderText="Incidents" ReadOnly="True" SortExpression="Incidents" UniqueName="Incidents">
</telerik:GridBoundColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>

 

protected void rcbFDriverAware_SelectedIndexChanged( object sender,RadComboBoxSelectedIndexChangedEventArgs e ) {
    string fe;
    switch( e.Text ) {
        case "Any":
            fe = "";
            break;
        case "Aware":
            fe = $"([iDriverAware] = 'true')";
            break;
        case "At Fault":
            fe = $"([iDriverFault] = 'true')";
            break;
        case "Both":
            fe = $"([iDriverAware] = 'true') AND ([iDriverFault] = 'true')";
            break;
        default:
            fe = "";
            break;
    }
    rgdepots.MasterTableView.DetailTables[0].FilterExpression = fe;
    rgdepots.MasterTableView.DetailTables[0].Rebind();
}
Eyup
Telerik team
 answered on 02 Aug 2017
3 answers
184 views
Hi,

I have implemented the SpellChecker in combination with RadEditor where I haven't used the RadEditor's AjaxSpellCheck tool, but I have pointed separate SpellChecker component to Radeditor's content area. I did this, because using the RadEditor's built-in AjaxSpellChecker doesn't provide the option of spell checking in new dialog box, but just an "inline" one, as far as I can see. All works fine unless I start using tables in RadEditor content. Some of the text is not properly recognized, this occures quite randomly.. Is there some way how to avoid this kind of situation?
Or is there a way, how to make RadEditor built in spell checker to work in "popup" not in "inline" mode?
Thank you, guys :0)

Adrian
Rumen
Telerik team
 answered on 02 Aug 2017
1 answer
377 views

I want to set the color of color picker when the Page Load. But it always cannot find the rad color picker control. It always get null.

protected void Page_Load(object sender, EventArgs e)
{
    if (IsPostBack == false)
    {               
        string szJS = "OptionSettingsLoad();";
        RadScriptManager.RegisterStartupScript(this, this.GetType(), "OptionSettingsLoad", szJS, true);
    }
}

 

The javascript has add the global function for initialize the TelerikDemo object and its function for color change.

I cannot find the color picker control by

var colorPickerDischargeTitleColor = $find("RadColorPickerDischargeTitleColor");

the color Picker"colorPickerDischargeTitleColor " always be null.

 

function (global, undefined) {
 
    var TelerikDemo = global.TelerikDemo = {};
 
    function OnClientColorChangeDischargeTitleColor(sender, eventArgs) {
 
        var colorPicker = $find("RadColorPickerDischargeTitleColor");
        var strColor = sender.get_selectedColor();
    }
 
    TelerikDemo.OnClientColorChangeDischargeTitleColor = OnClientColorChangeDischargeTitleColor;
 
    function OnClientColorChangeDischargeContentColor(sender, eventArgs) {
 
        //alert("Selected color is changed from " + eventArgs.get_oldColor() + " to " + sender.get_selectedColor() + ".");
        var colorPicker = $find("RadColorPickerDischargeContentColor");
        var strColor = sender.get_selectedColor();
    }
 
    TelerikDemo.OnClientColorChangeDischargeContentColor = OnClientColorChangeDischargeContentColor;
 
 
})(window);
 
 
function OptionSettingsLoad()
{
    var LS_titleColor = localStorage.getItem(DISCHARGE_TITLE_COLOR);
    var LS_contentColor = localStorage.getItem(DISCHARGE_CONTENT_COLOR);
 
    var colorPickerDischargeTitleColor = $find("RadColorPickerDischargeTitleColor");
    var colorPickerDischageContentColor = $find("RadColorPickerDischargeConetnteColor");
 
    //alert("LS_titleColor=" + LS_titleColor);
   
    HiddenDischargeTitleColor.value = LS_titleColor;
 
    if (colorPickerDischargeTitleColor != null && LS_titleColor != null)
    {      
        colorPickerDischargeTitleColor.set_selectedColor(LS_titleColor);
    }
 
    HiddenDischargeContentColor.value = LS_contentColor;
 
    if (colorPickerDischageContentColor != null && LS_contentColor != null)
    {
        colorPickerDischageContentColor.set_selectedColor(LS_contentColor);
    }
}

 

My RadColorPciker control in aspx as below:

<telerik:RadColorPicker ID="RadColorPickerDischargeTitleColor" runat="server" PaletteModes="HSB" ShowIcon="true" OnClientColorChange="TelerikDemo.OnClientColorChangeDischargeTitleColor" ></telerik:RadColorPicker>
 
<telerik:RadColorPicker ID="RadColorPickerDischargeContentColor" runat="server" PaletteModes="HSB" ShowIcon="true" OnClientColorChange="TelerikDemo.OnClientColorChangeDischargeContentColor" ></telerik:RadColorPicker>

 

Do I lose something to define or how to solve this problem?

章民
Top achievements
Rank 1
 answered on 02 Aug 2017
6 answers
263 views

Hello,

I have the following grid on my page where the first 6 columns are set to Display="False"  As you can see in the attached screenshot, chrome renders the grid correctly.  However IE hides the first 9 columns.  Even when setting all other rows Display="True" they still do not show up.

If I move those 6 Display="False" columns to the far right of the radgrid, it does render correctly on IE.

Is this a known bug, or am I missing something?  Thanks much.  Below is the code from my aspx page.

<telerik:RadGrid ID="RadGrid1" runat="server" DataSourceID="SqlDataSourceGrid">
                <GroupingSettings CollapseAllTooltip="Collapse all groups"></GroupingSettings>
                <MasterTableView AutoGenerateColumns="False" DataKeyNames="id" DataSourceID="SqlDataSourceGrid">
                    <Columns>
                        <telerik:GridBoundColumn DataField="id" DataType="System.Int32" FilterControlAltText="Filter id column" HeaderText="id" ReadOnly="True" SortExpression="id" UniqueName="id" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="hdr_id" DataType="System.Int32" FilterControlAltText="Filter hdr_id column" HeaderText="hdr_id" SortExpression="hdr_id" UniqueName="hdr_id" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="fjobno" FilterControlAltText="Filter fjobno column" HeaderText="fjobno" SortExpression="fjobno" UniqueName="fjobno" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="process" FilterControlAltText="Filter process column" HeaderText="process" SortExpression="process" UniqueName="process" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="operator" DataType="System.Decimal" FilterControlAltText="Filter operator column" HeaderText="operator" SortExpression="operator" UniqueName="operator" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="tower" DataType="System.Int32" FilterControlAltText="Filter tower column" HeaderText="tower" SortExpression="tower" UniqueName="tower" Display="false">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="date" DataType="System.DateTime" FilterControlAltText="Filter date column" HeaderText="date" SortExpression="date" UniqueName="date" DataFormatString="{0:d}">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="shift" DataType="System.Int32" FilterControlAltText="Filter shift column" HeaderText="shift" SortExpression="shift" UniqueName="shift">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="reelno" DataType="System.Decimal" FilterControlAltText="Filter reelno column" HeaderText="reelno" SortExpression="reelno" UniqueName="reelno">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="FWRM" DataType="System.Decimal" FilterControlAltText="Filter FWRM column" HeaderText="FWRM" SortExpression="FWRM" UniqueName="FWRM">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="WRM" DataType="System.Decimal" FilterControlAltText="Filter WRM column" HeaderText="WRM" SortExpression="WRM" UniqueName="WRM">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="WIM" DataType="System.Decimal" FilterControlAltText="Filter WIM column" HeaderText="WIM" SortExpression="WIM" UniqueName="WIM">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="FWIM" DataType="System.Decimal" FilterControlAltText="Filter FWIM column" HeaderText="FWIM" SortExpression="FWIM" UniqueName="FWIM">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="CONIW" DataType="System.Decimal" FilterControlAltText="Filter CONIW column" HeaderText="CONIW" SortExpression="CONIW" UniqueName="CONIW">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Speed" DataType="System.Decimal" FilterControlAltText="Filter Speed column" HeaderText="Speed" SortExpression="Speed" UniqueName="Speed">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Settings" DataType="System.Decimal" FilterControlAltText="Filter Settings column" HeaderText="Settings" SortExpression="Settings" UniqueName="Settings">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="WT" FilterControlAltText="Filter WT column" HeaderText="WT" SortExpression="WT" UniqueName="WT">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Output" DataType="System.Decimal" FilterControlAltText="Filter Output column" HeaderText="Output" SortExpression="Output" UniqueName="Output">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="LotRM" FilterControlAltText="Filter LotRM column" HeaderText="LotRM" SortExpression="LotRM" UniqueName="LotRM">
                        </telerik:GridBoundColumn>
                        <telerik:GridBoundColumn DataField="Comment" FilterControlAltText="Filter Comment column" HeaderText="Comment" SortExpression="Comment" UniqueName="Comment">
                        </telerik:GridBoundColumn>
                    </Columns>
                </MasterTableView>
            </telerik:RadGrid>

 

Here is my versioning information.

Microsoft Visual Studio Professional 2017 
Version 15.1 (26403.7) Release
VisualStudio.15.Release/15.1.0+26403.7
Microsoft .NET Framework
Version 4.6.01055

Installed Version: Professional

Visual Basic 2017   00369-60000-00001-AA675
Microsoft Visual Basic 2017

Visual C# 2017   00369-60000-00001-AA675
Microsoft Visual C# 2017

Visual C++ 2017   00369-60000-00001-AA675
Microsoft Visual C++ 2017

Application Insights Tools for Visual Studio Package   8.6.00209.10
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 2017   15.0.30320.0
ASP.NET and Web Tools 2017

ASP.NET Web Frameworks and Tools 2017   5.2.50303.0
For additional information, visit https://www.asp.net/

Azure App Service Tools v3.0.0   15.0.30209.0
Azure App Service Tools v3.0.0

Azure Data Lake Node   1.0
This package contains the Data Lake integration nodes for Server Explorer.

Azure Data Lake Tools for Visual Studio   2.2.5000.0
Microsoft Azure Data Lake Tools for Visual Studio

Common Azure Tools   1.9
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

JavaScript Language Service   2.0
JavaScript Language Service

KofePackagePackage Extension   1.0
KofePackagePackage Visual Studio Extension Detailed Info

Microsoft Azure Hive Query Language Service   2.2.5000.0
Language service for Hive query

Microsoft Azure Tools   2.9
Microsoft Azure Tools for Microsoft Visual Studio 2017 - v2.9.50131.1

Microsoft MI-Based Debugger   1.0
Provides support for connecting Visual Studio to MI compatible debuggers

Microsoft Visual Studio VC Package   1.0
Microsoft Visual Studio VC Package

NuGet Package Manager   4.1.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.

SQL Server Data Tools   15.1.61702.140
Microsoft SQL Server Data Tools

Telerik ASP.NET AJAX VSExtensions   2017.2.501.0
Progress® Telerik® UI for ASP.NET AJAX Visual Studio extensions

Telerik ASP.NET Core VSExtensions   2017.2.502.0
Progress® Telerik® UI for ASP.NET Core Visual Studio extensions

Telerik ASP.NET MVC VSExtensions   2017.2.502.0
Progress® Telerik® UI for ASP.NET MVC Visual Studio extensions

Telerik WinForms VSExtensions   2017.2.501.0
Progress® Telerik® UI for WinForms Visual Studio extensions

Telerik WPF VSExtensions   2017.2.501.0
Progress® Telerik® UI for WPF Visual Studio extensions

ToolWindowHostedEditor   1.0
Hosting json editor into a tool window

TypeScript   2.1.5.0
TypeScript tools for Visual Studio

Visual Studio tools for CMake   1.0
Visual Studio tools for CMake

 

Vessy
Telerik team
 answered on 01 Aug 2017
1 answer
179 views

We have RadGrids configured to export to CSV, Excel, or PDF. The file names are explicitly set in GridExportSettings.FileName based on grid content, such as "Patient Status Choices". In IE11, this file name is changed by replacing blanks with plus signs, e.g., "Patient+Status+Choices". This does not happen in Edge or Chrome.

Is there a way to get IE to export using the file name exactly as we specify?

Vessy
Telerik team
 answered on 01 Aug 2017
0 answers
108 views

I've next code that handle rowFormatting my cells:

private void gridViewRaces_RowFormatting(object sender, RowFormattingEventArgs e) {

    foreach (var cellColumn in e.RowElement.Data.Cells) {

    var cellInfo = cellColumn as GridViewCellInfo;

    if (cellInfo != null) {

    cellInfo.Style.DrawFill = true;

    if (cellInfo.ColumnInfo.Name == "columnContactProducerName") {

        cellInfo.Style.DrawFill = true; cellInfo.Style.BackColor = Color.Yellow; }

   else if (cellInfo.ColumnInfo.Name == "columnTransport") { cellInfo.Style.BackColor = Color.Yellow; }

   else { cellInfo.Style.BackColor = ColorTranslator.FromHtml((e.RowElement.Data.DataBoundItem as RaceForListDto).Color); } }

}

}
but my cells aren't painting. How to paint some cells in rows on dataBinding?

Nickolay
Top achievements
Rank 1
 asked on 01 Aug 2017
8 answers
444 views

Hi,

I am testing the RADSpreadsheet control and have the following error when the page loads:

Unhandled Exception - Unable to get property '_preInitialize' of undefined null reference
Telerik.Web.UI.RadListBox._preInitialize("RadSpreadsheet1_FilterMenu_ValueListBox","0")

I have the latest version of the UI for ASP.NET AJAX 2016.3.1027

Developing using VS 2015 Framework 4.5.2

Thanks.

Jon
Top achievements
Rank 1
 answered on 01 Aug 2017
0 answers
73 views
I am using this sort of code in the fiddle given below.

http://jsfiddle.net/darrenarbell/4HTEr/

When editing the cell content ,the content value vanished.

I am not sure it's a bug or not ?How can i fix that?

Deeply appreciated your help.
Aaron
Top achievements
Rank 1
 asked on 01 Aug 2017
0 answers
165 views

I was trying to have the validation happening at client side by adding the OnCommand ClientEvents to the grid.  If invalid, the OnCommand will be cancelled.

 

However, after adding it in, it caused the Grid control to throw error "Unable to get property 'showInsertItem' of undefined or null reference" (can be viewed thru debug within IE).  This has caused the "Add new Record" button of the Grid not working.  If I take out the ClientEvents lines out, the affected function will be resumed.  The funny thing was that it seemed it only got problem with "OnCommand".  I tried few other, such as OnItemCreated, OnDoubleClick, without issues at all.

Any ideas?  Attached please find my code.

@ Control Language="C#" AutoEventWireup="false" CodeBehind="Data018_WRN_RecallQryByVin.ascx.cs"
    Inherits="HMSA.HinoConnect.UI.Web.CustomPageElements.Data018_WRN_RecallQryByVin" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>

<style type="text/css">
    .Dta018WrnRecallQdsp{
        color:red;
        width:100%;
    }
</style>

<script type="text/javascript">
    var searchedTxt = "";
    var hdnapiUrl;
    var hdnWebApiToken;

    function DspRadAjaxLoadingPanle(sender, _show) {
        var loadingPanel = $find("<%= Dta018WrnRecallQ_RadAjaxLoadingPanel.ClientID %>");

        if (_show) {
            loadingPanel.show(sender.get_id());
        }
        else {
            loadingPanel.hide(sender.get_id());
        }
    }//DspRadAjaxLoadingPanle

    function Dta018WrnRecallQEditTmpltVinRadcombo_RequestData(sender, eventArgs) {
        var _txt = sender.get_text();
        var _cnt = sender.get_items().get_count();

        //serial number must have length of 6 and last 5 are all numbers
        if (_txt.length != 6 || (searchedTxt == _txt && _cnt>0) || (_txt.length == 6 && !_txt.substring(1).match(/^\d+$/))) {
            eventArgs.set_cancel(true);
            return;
        }

        hdnWebApiToken = document.getElementById("<%=Dta018WrnRecallQ_webAPItoken.ClientID %>");
        hdnapiUrl = document.getElementById("<%=Dta018WrnRecallQ_apiUrl.ClientID %>");

        DspRadAjaxLoadingPanle(sender, true);

        $.ajax({
            url: hdnapiUrl.value + '/api/v1/Ids_infp07/GetVinBySearchToken/?SearchToken=' + _txt + '&DlrCode= &hmsastaff=Y',
            dataType: 'json',
            headers: {
                "Authentication": hdnWebApiToken.value
            },
            type: 'GET',
            contentType: "application/json;charset=utf-8",
            crossDomain: true,

            success: function (data, textStatus, xhr) {
                DspRadAjaxLoadingPanle(sender, false);

                sender.clearItems();
                var recCount = 0;
                searchedTxt = _txt;

                $.each(data, function (key, item) {
                    var comboItem = new Telerik.Web.UI.RadComboBoxItem();
                    var _vin = item._VIN_I7.trim();

                    comboItem.set_text(_vin);
                    comboItem.set_value(_vin);
                    sender.get_items().add(comboItem);
                    recCount++;
                });

                if (recCount > 0) {
                    sender.showDropDown();
                }
                return;
            },
            error: function (error, status, xhr) {
                DspRadAjaxLoadingPanle(sender, false);

                searchedTxt = '';
                var _ermsg = "error: ";

                if (error) {
                    if (error.responseText) {
                        _ermsg = _ermsg + error.responseText;
                    }
                }

                _ermsg = _ermsg + "; status: ";

                if (status) {
                    _ermsg = _ermsg + status;
                }

                _ermsg = _ermsg + "; xhr: ";

                if (xhr) {
                    _ermsg = _ermsg + xhr;
                }

                alert(_ermsg);

                return;
            }
        });//ajax

        eventArgs.set_cancel(true);
    }//Dta018WrnRecallQEditTmpltVinRadcombo_RequestData
</script>

<telerik:RadCodeBlock ID="RadCodeBlock1" runat="server">
        <script type="text/javascript">
            function RaiseCommand(sender, eventArgs) {
                
                alert("Hi");
            }
        </script>
</telerik:RadCodeBlock>

<asp:PlaceHolder ID="ViewPlaceHolder" runat="server" Visible="false">
    <p>
        View mode</p>
    <asp:Label ID="SampleOutput" runat="server"></asp:Label>

    <div class="row">
            <p id="Dta018WrnRecallQ_radgrd_divMsgs" runat="server">
                <asp:Label ID="Dta018WrnRecallQ_radgrd_divMsgs_lbl1" runat="server" EnableViewState="False" Font-Bold="True" ForeColor="#FF8080">
                </asp:Label>
                <asp:Label ID="Dta018WrnRecallQ_radgrd_divMsgs_lbl2" runat="server" EnableViewState="False" Font-Bold="True" ForeColor="#00C000">
                </asp:Label>
            </p>
    </div> 

    <telerik:RadAjaxLoadingPanel runat="server" ID="Dta018WrnRecallQ_RadAjaxLoadingPanel" />

    <telerik:RadAjaxManager runat="server" ID="Dta018WrnRecallQ_radajaxmgr" DefaultLoadingPanelID="Dta018WrnRecallQ_RadAjaxLoadingPanel" ClientEvents-OnRequestStart="mngRequestStarted">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="Dta018WrnRecallQ_radgrd">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="Dta018WrnRecallQ_radgrd" LoadingPanelID="Dta018WrnRecallQ_RadAjaxLoadingPanel"></telerik:AjaxUpdatedControl>
                    <telerik:AjaxUpdatedControl ControlID="Dta018WrnRecallQ_radgrd_divMsgs"></telerik:AjaxUpdatedControl>
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>           
    </telerik:RadAjaxManager>

    <telerik:RadFormDecorator RenderMode="Lightweight" ID="Dta018WrnRecallQ_RadFormDecorator" runat="server" DecorationZoneID="Dta018WrnRecallQ_demo" DecoratedControls="All" EnableRoundedCorners="false" />

    <div id="Dta018WrnRecallQ_demo" class="demo-container no-bg">
        <telerik:RadGrid RenderMode="Lightweight" runat="server" ID="Dta018WrnRecallQ_radgrd" AutoGenerateColumns="false" AllowPaging="true" Skin="Silk"
             Width="40%" style="margin-left: auto !important; margin-right: auto !important;" OnNeedDataSource="Grid_NeedDataSource" OnUpdateCommand="Grid_UpdateCommand" 
            OnInsertCommand="Grid_UpdateCommand">
                    
            <MasterTableView CommandItemDisplay="Top" DataKeyNames="Vin" ClientDataKeyNames="Vin" InsertItemPageIndexAction="ShowItemOnLastPage">
                <CommandItemSettings AddNewRecordText="Add New Vin#" ShowRefreshButton="false" />
                
                <Columns>                       
                    <telerik:GridBoundColumn DataField="Vin" HeaderText="Vin #" ReadOnly="true"
                            ForceExtractValue="Always" ConvertEmptyStringToNull="true" />                 
                    <telerik:GridEditCommandColumn UniqueName="Dta018WrnRecallQ_GridEditCommandColumn" ButtonType="ImageButton"/>                  
                </Columns>

                <EditFormSettings EditFormType="Template">
                    <FormTemplate>
                        <table id="Dta018WrnRecallQ_edit_form_tmplt" style="border-collapse: collapse; border-spacing: 2px; padding: 1px; width: 100%; border-style:hidden;">
                            <tr>
                                <td>Vin #:</td>
                                <td>
                                    <telerik:radcombobox id="Dta018WrnRecallQ_edit_form_tmplt_vin" runat="server" Text='<%# Bind("Vin") %>' TabIndex="1" Width="100%"
                                        datatextfield="text" datavaluefield="value" AllowCustomText="true" EmptyMessage="Type serial number to search..."
                                        MarkFirstMatch="true" EnableLoadOnDemand="true" OnClientItemsRequesting ="Dta018WrnRecallQEditTmpltVinRadcombo_RequestData"/>
                                </td>
                                <td>
                                    <asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Insert" : "Update" %>'
                                        runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>'></asp:Button> &nbsp;
                                    <asp:Button ID="btnCancel" Text="Cancel" runat="server" CausesValidation="False"
                                        CommandName="Cancel"></asp:Button>
                                </td>
                            </tr>       
                        </table>
                    </FormTemplate>
                </EditFormSettings>
            </MasterTableView>
            
            <PagerStyle Mode="NextPrevAndNumeric" />   
            
            <ClientSettings>
                <ClientEvents OnCommand="RaiseCommand" />
            </ClientSettings>    
        </telerik:RadGrid><%--Dta018WrnRecallQ_radgrd--%>

        <label id="Dta018WrnRecall_grid_err" runat="server" class="Dta018WrnRecallQdsp">err</label> 
    </div><%--Dta018WrnRecallQ_demo--%>

    <asp:HiddenField ID="Dta018WrnRecallQ_apiUrl" runat="server"/>
    <asp:HiddenField ID="Dta018WrnRecallQ_webAPItoken" runat="server"/>
</asp:PlaceHolder><%--ViewPlaceHolder--%>

<asp:PlaceHolder ID="EditPlaceHolder" runat="server" Visible="false">
    <p>
        Edit mode (this is an optional mode in case you want publishers to be able to edit
        and save settings for this element).</p>
    Setting :
    <asp:TextBox ID="SampleSetting" runat="server" />
</asp:PlaceHolder>

Jack
Top achievements
Rank 1
 asked on 01 Aug 2017
Narrow your results
Selected tags
Tags
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?