I'm trying to select an item value from DropDownTree which impeded in a RadGrid , in the add new record in the radGrid then select the item from dropdownTree , but i can't find a way to access the radgrid cell to update its value by the DropDownTree value ,
the scenario is get the itemCode value from DropDownTree then search in Database to get the Item Price then put the price in the RadGrid
Protected Sub RadDropDownTree1_EntryAdded(sender As Object, e As DropDownTreeEntryEventArgs)Ok, so I am working on a project where inside a RadWizard control I am adding dynamically creating RadDropDownList controls.
RadDropDownList ddl = new RadDropDownList() { ID = string.Format("FrmDDL{0}", i) };
I then call a method to select the selected RadDropDownListItem (Now using every method I can think of to select the value) (The RadDropDownList is passed to the method as 'r')
foreach (DropDownListItem l in r.Items)
{
if (string.Compare(value, l.Value) == 0)
{
l.Selected = true;
r.SelectedIndex = i;
r.SelectedValue = l.Value;
r.SelectedText = l.Text;
}
i++;
}
Now where it gets interesting is when you look at the generated code
<div id="FrmDDL0" class="RadDropDownList" style="width:300px;" tabindex="0">
<span class="rddlInner">
<span class="rddlFakeInput">X4</span>
<span class="rddlIcon"><!-- --></span>
</span>
<div class="rddlSlide" id="FrmDDL0_DropDown" style="display:none;">
<div class="rddlPopup rddlPopup_SI">
<ul class="rddlList">
<li class="rddlItem"> </li>
<li class="rddlItem">X1</li>
<li class="rddlItem">X2</li>
<li class="rddlItem">X3</li>
<li class="rddlItem rddlItemSelected">X4</li>
</ul>
</div>
</div>
<input id="FrmDDL0_ClientState" name="FrmDDL0_ClientState" type="hidden" autocomplete="off">
</div>
You can clearly see that the _ClientState control is not populated with the selected value even though the <li> item has the 'rddlItemSelected' class. For comparison this is what it looks like if I selected a value from the RadDropDownList from the UI.
<input id="FrmDDL0_ClientState" name="FrmDDL0_ClientState" type="hidden" autocomplete="off" value="{"enabled":true,"logEntries":[],"selectedIndex":4,"selectedText":"X4","selectedValue":"X4"}">
So the question really becomes, when using the RadWizard and its back and forward buttons, how do I persist client selection on a dynamically created RadDropDownList
So basically when I run my ASP.NET project I get this error, the thing is I used to get this error with Newtonsoft.Json, so what I did I went to my web.config and checked the <bindingRedirect>
<dependentAssembly>
<assemblyIdentityname="Telerik.Web.UI" publicKeyToken="" culture="neutral" />
<bindingRedirectoldVersion="0.0.0.0-2020.2.617.45" newVersion="2020.2.617.45" />
</dependentAssembly>
So after I went to references and checked if the version matched with the web config and it did
I have a Radgrid with AllowKeyboardNavigatin="true"
When using the Keyboard arrows to move around the grid, if the arrow comes into a RadDatePicker, or even a System.DateTime datatype, the value changes by 1 month depending on if the up or down arrow was used to enter that cell.
So
1. The cell becomes dirty just by using the up / down arrow to go past them.
2. The cell actually changes value just by using the arrow to navigate past it.
Is there any work around or property I can set to keep this from happening but also allow use of the keyboard arrows?
** If you hold down the ctrl key along with the arrow key this DOES NOT happen. This could be a hard training topic for my users.
Hopefully there is another way to do this.
Thanks.
I have the following RadClientDataSource:
<telerik:RadClientDataSource runat="server" ID="rdsCounty">
<DataSource>
<WebServiceDataSourceSettings ServiceType="GeoJSON">
<Select Url="Arizona.json" DataType="JSON" ContentType="application/json" />
</WebServiceDataSourceSettings>
</DataSource>
</telerik:RadClientDataSource>
...which is being consumed by a RadMap (along with other RadClientDataSource controls) like so:
<telerik:RadMap runat="server" ID="rdmTest" Width="800" Height="600">
<ClientEvents OnShapeCreated="configureShape" OnShapeClick="clickShape" OnLoad="zoomToContiguousUSA" />
<LayersCollection>
<telerik:MapLayer Type="Bing" Key="my key here" />
<telerik:MapLayer Type="Shape" ClientDataSourceID="rdsState" />
<telerik:MapLayer Type="Shape" ClientDataSourceID="rdsCounty" />
</LayersCollection>
</telerik:RadMap>
Is it possible to change the URL from "Arizona.json" to "Illinois.json"? I want to do this on the client, using javascript, in response to user action. I've looked at the client side API for the RadClientDataSource and I don't see how this could be done. I could also load Illinois.json manually, but I've tried something like this:
map.layers[2].setDataSource(JSON.parse(IllinoisFileContents));
...but that doesn't seem to work.
Is there a proper technique for this?
Hello,
I have an if else condition which is covered by RadCodeBlock. When I try to bind any control as an updated control in RadCodeBlock by using RadAjaxManagerProxy, it throws below error.
For example; rcbCustomer is binded to rlCustomer. But it causes error. Because rlCustomer is in RadCodeBlock.
Here is RadCodeBlock;
<telerik:RadCodeBlock ID="rcodeCustomer" runat="server">
<table class="fieldset-table">
<% if (User.IsInRole("ADMIN"))
{ %>
<tr>
<td>
<telerik:RadLabel runat="server" Text="Customer" Font-Size="Large" ForeColor="Black" />
</td>
<td>
<telerik:RadLabel runat="server" Text=":" ForeColor="Black" Font-Bold="false" />
</td>
<td>
<telerik:RadComboBox MarkFirstMatch="true" ID="rcbCustomer" EmptyMessage="Please Select Customer" runat="server" Width="100%" DataValueField="ID" DataTextField="Name" AutoPostBack="true" OnSelectedIndexChanged="rcbCustomer_SelectedIndexChanged" />
<asp:RequiredFieldValidator
runat="server"
Display="Dynamic"
ControlToValidate="rcbCustomer"
ErrorMessage="Customer is required!"
CssClass="validator" />
</td>
<td class="center" style="width: 100px">
<telerik:RadButton runat="server" ID="rbCustomerReload" ToolTip="Reload Customers" Icon-PrimaryIconCssClass="rbRefresh" BackColor="White" OnClick="rbCustomerReload_Click" />
<telerik:RadLinkButton runat="server" ToolTip="Add New Customer" Icon-CssClass="rbAdd" BackColor="White" Target="_blank" NavigateUrl="AdminUser.aspx" />
</td>
</tr>
<tr>
<td colspan="3">
<telerik:RadLabel ID="rlCustomer" runat="server" ForeColor="#333333" Font-Bold="false" Font-Size="Medium" Visible="false" />
</td>
</tr>
<%} %>
</table>
</telerik:RadCodeBlock>
Here is RadAjaxManagerProxy;
<telerik:AjaxSetting AjaxControlID="rcbCustomer">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="rlCustomer" LoadingPanelID="RadAjaxLoadingPanel" />
<telerik:AjaxUpdatedControl ControlID="rcbCustomerContact" LoadingPanelID="RadAjaxLoadingPanel" />
<telerik:AjaxUpdatedControl ControlID="rlCustomerContact" LoadingPanelID="RadAjaxLoadingPanel" />
<telerik:AjaxUpdatedControl ControlID="rcbCustomerAddress" LoadingPanelID="RadAjaxLoadingPanel" />
<telerik:AjaxUpdatedControl ControlID="rlCustomerAddress" LoadingPanelID="RadAjaxLoadingPanel" />
</UpdatedControls>
</telerik:AjaxSetting>
Error;
Could you please help?
Thanks,
I have a radgrid that gets it's data from a Stored Proc and a gridview.DataBind() . It works as expected, but when I edit one cell and SAVE changes utilizing the Save Changes Command Button, all my "Editable" columns now seem to have newValues even if I did not edit them.
gvResults.DataSource = DAL.ExecuteDataset(30, "GetProductionDateTrackingInfo", parms.ToArray());
Example one column is a RadDatePicker with a MinDate
<EditItemTemplate>
<telerik:RadDatePicker RenderMode="Lightweight" ID="MB_Production_DatePicker" MinDate="1/1/1970" runat="server" DbSelectedDate='<%# Bind("MB_Production_Date") %>'> </telerik:RadDatePicker>
</EditItemTemplate>
The newValues hashtable has this column as changed eventhough I didn't click in it.
How do I set the grid to No changes so only when a user clicks on a cell and changes it shows up in the newValues hashtable?
Hello
I am using the RadGrid which has default filter on load data, so that when the Web page is first loaded, it presents an already-filtered data
For this MasterTableView has property FilterExpression with WHERE clause for filtering items. On this part everything is Ok but issue I have is that the filter on the column isn't checked, so f.e user doesn't know which filter is applied.
This picture above better depicts what I want to do
As you see, when filter is applied it's checkbox is checked, I'm looking for this kind of functionality only that on page load, data is already-filtered
I tried documentation but couldn't find anything related to this issue, so maybe you can help.
There's difference in behavior between IE11 and Edge mode IE11 when the radEditor is used inside a window.showModalDialog
For the moment, we cannot use a replacement for window.showModalDialog because the website use frames everywhere (as a template for navigation. Ex: frame for left menu, frame for top, frame for center content, etc) in a way that a javascript style showmodalDialog doesn't block UI interaction every where in the page (as with the IE showModalDialog).
Context :
Thank you for help,
Jean-François Ferland
I need to insert a value in a cell from another radtree value in server side but the problem is i can not know the current index when the record is new record, the 0 index update the first record not the new record
Dim ItemGrid As RadGrid = CType(Page.Master.FindControl("MainContent").FindControl("RadGrid2"), RadGrid)