Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
282 views
As i'm binding value in client site for combobox like this way in Jquery.

$.each(response, function (index, value) {
let item = new Telerik.Web.UI.RadComboBoxItem();
item.set_text(value.EnggName);
item.set_value(value.EngineerId);
$find('<%= cmb_EnggList.ClientID%>').get_items().add(item);
});

and it binds the value correctly but when i post it in the server like this.

foreach (Telerik.Web.UI.RadComboBoxItem EngineerId in cmb_EnggList.Items)// it gives empty items
{
  if (EngineerId.Checked)
  {
       Guid GuidEngineerId = new Guid(EngineerId.Value);
      _JobCalendarEngg = new JobCalendarEngg();
      _JobCalendarEngg.JobCalendarEnggId = Guid.NewGuid();
      _JobCalendarEngg.JobCalendarId = JobCalendarId;
      _JobCalendarEngg.EngineerId = GuidEngineerId;
      en.JobCalendarEnggs.Add(_JobCalendarEngg);
  }
}
It gives me empty 
cmb_EnggList.Items
 but when i bind it like this.

cmb_EnggList.Items.Clear();
foreach (var record in records)
{
   var EnggName = (from k in en.EngineersLibraries
   where k.EngineerId == record.EngineerId select k).FirstOrDefault(); Telerik.Web.UI.RadComboBoxItem item = new
   Telerik.Web.UI.RadComboBoxItem(EnggName.EngineerName, EnggName.EngineerId.ToString());
   cmb_EnggList.Items.Add(item);
}

And post it will give me binded value so in the whole scenario if i bind my drop down in Jquery it binds value in the client page and after post method it gives me an empty list but when i bind the drop down in my server end and when i post it will get me the binded list.
So i require my Jquery binded value to be get in my server list. f
oreach (Telerik.Web.UI.RadComboBoxItem EngineerId in cmb_EnggList.Items)
Doncho
Telerik team
 answered on 02 Oct 2020
2 answers
253 views
I want to populate a RadGrid with SharePoint 2010 list data. I cannot figure out how this is accomplished.

Here is my ASPX page:
<SPWebControls:SPDataSource runat="server" ID="dsclientmatter" DataSourceMode="ListItem" UseInternalName="true">
  <SelectParameters>
      <asp:Parameter Name="WebUrl" DefaultValue="/configuration/" />
      <asp:Parameter Name="ListID" DefaultValue="4056449D-1884-4C79-AAAD-CD0ABEB2F854" />
      <asp:Parameter Name="ListItemID" DefaultValue="1" />
  </SelectParameters>
</SPWebControls:SPDataSource>
 
<telerik:RadGrid ID="RadGrid1" runat="server" GridLines="None" ShowStatusBar="true" PageSize="7" AllowPaging="True" DataSourceID="dsclientmatter" >
    <ClientSettings>
        <Selecting AllowRowSelect="True" />
    </ClientSettings>
<MasterTableView datasourceid="">
<CommandItemSettings ExportToPdfText="Export to PDF"></CommandItemSettings>
 
<RowIndicatorColumn Visible="True" FilterControlAltText="Filter RowIndicator column">
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
 
<ExpandCollapseColumn Visible="True" FilterControlAltText="Filter ExpandColumn column">
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
 
<EditFormSettings>
<EditColumn FilterControlAltText="Filter EditCommandColumn column"></EditColumn>
</EditFormSettings>
</MasterTableView>
 
<FilterMenu EnableImageSprites="False"></FilterMenu>
</telerik:RadGrid>

Here is my code-behind:
protected void Page_Load(object sender, EventArgs e)
        {
            SPSite site = new SPSite("http://abcdev");
             
            using (SPWeb web = site.OpenWeb())
            {
                SPList clientlist = web.Lists.TryGetList("clientmatter");
                DataTable dt = new DataTable();
                SPQuery query = new SPQuery();
                query.ViewFields = "<Where><Eq><FieldRef Name='clientid'/><Value Type='Text'>12345</Value></Eq></Where>";
                SPListItemCollection items = clientlist.GetItems(query);
                if(items != null)
                {
                    if(items.Count > 0)
                    {
                        dt = items.GetDataTable();                       
                        GridView1.DataSource = dt;
                        GridView1.DataBind();
                         
                    }
                }
            }
        }

I don't know if this is the best way to start, but I do know something is wrong because I cant render any data. Plus, I don't understand why by RadGrid ID will not compile. I get an error stating "The name 'GridView1' does not exist in the current context". Why. That is the ID of my RadGrid.

My end goal is to create a RadGrid that I can filter by individual columns, such as: name, client#, topic, etc. I am not sure if the filtering allows for multiple entries, but I would like to be able to filter on more than one criteria. Also, wildcard searches are very important.

Thank you for the help!
Pistle
Top achievements
Rank 1
Veteran
 answered on 01 Oct 2020
4 answers
239 views
I used the Telerik Control Panel from my SharePoint 2010 server to install the latest ASP.NET AJAX controls. However, the controls are not available when adding Web parts to a SharePoint page. Also, I created a new visual Web part from within Visual Studio 2010 and added a RadComboBox. I then deployed this Web part to my SharePoint server. Visual Studio displays a message that it successfully deployed the Web part. However, after attempting to add my newly deployed Web part to a page, I receive the error "An unexpected error has occurred...."

Is there something beyond the Telerik Control Panel automated installation that is required to make the Telerik AJAX controls available to SharePoint in custom Web parts and on their own?
Pistle
Top achievements
Rank 1
Veteran
 answered on 01 Oct 2020
2 answers
106 views
Hello,

We are currently in the process of upgrading a number of site collections from SharePoint 2010 to SharePoint 2013.
A few of these site collections uses Telerik Components, for example Telerik RadEditor.

If we open one of these sites we get the following error message:

Could not load file or assembly 'RadEditorSharePoint, Version=5.7.3.0, Culture=neutral, PublicKeyToken=1f131a624888eeed' or one of its dependencies. The system cannot find the file specified.

Our plan is to not do a visual upgrade but instead keep running the sites in SP2010 UI mode whenever possible. We're not sure if this is supported for the Telerik SharePoint 2013 web parts?
What would be the best way to handle this? We assume we have to install the 2013 version of the Telerik components.

We tried installing Telerik_Web_Parts_For_Sharepoint2013_2015_2_826_Trial.msi but that doesn't seem to work. We still get the same error message.

Any help or suggestions would be much appreciated.
Pistle
Top achievements
Rank 1
Veteran
 answered on 01 Oct 2020
3 answers
281 views
In certain situation we need to pass data from webpart to another webpart present in the same site. To implement the connection functionality between WebParts, we should create an Interface .This interface will be implemented by both the provider and consumer classes.
 
Then we will use the ConnectionProvider and ConnectionConsumer attribute to make the connection between the two webpart.

EXAMPLE:
1.  Interface :  
  
    public interface Test
    {
        string Name { get; set; }
    }

Thanks,
Bijayani

Pistle
Top achievements
Rank 1
Veteran
 answered on 01 Oct 2020
2 answers
765 views

We are working on a custom web form for SharePoint 2013. It is a visual web part and have a form which have several telerik controls. It is a big form. Earlier we developed it in Visual Studio 2012 and now we are working Visual Studio 2013. Now issue is, It is not generating designer file i.e. ascx.g.cs and giving error on every build. When we checked designer file, it is empty. We tried every possible solutions but not able to generate designer file and Visual Studio hangs if we open ascx file in design mode.

Please help immediately.

Thanks,

 

Pistle
Top achievements
Rank 1
Veteran
 answered on 01 Oct 2020
19 answers
465 views

We are using telerik version 2017.2.711.45 in our application. We are currently experiencing an issue in IE 11 with Radbutton when rendered as 'lightweight' mode does not display the icons. After some research I found that enabling the font download in the internet explorer settings fixes the issue, but as part of admin policy we are not allowed to make this settings change.

Can you please provide any work around for this.

 

James
Top achievements
Rank 1
 answered on 01 Oct 2020
8 answers
1.8K+ views
Hi!

I use the file explorer and have a problem I can't find a solution for.
In my file explorer I list my App_Themes folder. Is there a way to set file extensions that are allowed in specific folders at upload?
I just want to enable upload of .css-files in the /css folder and only images such as .jpg, .gif, .png etc in the /images folder.

Is there functionality in file explorer or upload control to help me with my problem.

Maybe I can use some of the javascript events, but I hope there is a simpler solution.

Regards

Christian Persson
Vessy
Telerik team
 answered on 30 Sep 2020
3 answers
147 views

Hi,

I try to filter radgrid data and get below exception

 

Unhandled exception at line 6, column 85898 in http://localhost:29227/Telerik.Web.UI.WebResource.axd?_TSM_HiddenField_=RadScriptManager1_TSM&compress=1&_TSM_CombinedScripts_=;;System.Web.Extensions,+Version=4.0.0.0,+Culture=neutral,+PublicKeyToken=31bf3856ad364e35:en-IN:4feca508-514b-48c0-a162-7fa9c360d783:ea597d4b:b25378d2;Telerik.Web.UI,+Version=2018.1.117.45,+Culture=neutral,+PublicKeyToken=121fae78165ba3d4:en-IN:6d514cb9-2739-4112-a25a-b6efc64747ba:16e4e7cd:ed16cbdc:33715776:58366029:f7645509:24ee1bba:f46195d3:8674cba1:7c926187:88144a7a:b7778d6c:c08e9f8a:e085fe68:2003d0b8:c128760b:1e771326:aa288e2d:258f1c72:59462f1:a51ee93e:e330518b:c8618e41:e4f8f289:1a73651d:333f8d94:874f8ea2:b2e06756:92fe8ea0:fa31b949:4877f69a:19620875:490a9d4e:bd8f85e4:6b3f73b3:6d43f6d9
0x80070057 - JavaScript runtime error: Invalid argument. occurred

Harshal
Top achievements
Rank 1
 answered on 30 Sep 2020
4 answers
164 views

Im using two radtextboxes within  GridTemplateColumns. Im trying to use an onblur event but when I make some tests for some reazon, the attached function is firing several times. What is causing this behavior?

Aspx

1.<telerik:GridTemplateColumn UniqueName="VisibleAccCode" HeaderText="Código Cuenta"
2. HeaderStyle-HorizontalAlign="Center"
3. ItemStyle-HorizontalAlign="Center" HeaderStyle-Width="250px">
4.         <ItemTemplate>
5.                 <telerik:RadTextBox ID="TxtAccCode" runat="server" Width="85%"/>
6.         </ItemTemplate>
7.</telerik:GridTemplateColumn>
 

 

 

VB
01.
Dim TxtAccCode As RadTextBox = CType(item.FindControl("TxtAccCode"), RadTextBox)
02.Dim TxtAcctName As RadTextBox = CType(item.FindControl("TxtAcctName"), RadTextBox)
03. 
04.Dim sJsFunction As String
05. 
06.sJsFunction = "function (s,a){BuscarAccCode(s,a," & RowIndex & ");}"
07. 
08.If TxtAccCode IsNot Nothing Then
09.        TxtAccCode.ClientEvents.OnBlur = sJsFunction
10.End If
11. 
12.sJsFunction = "function (s,a){BuscarAccName(s,a," & RowIndex & ");}"
13. 
14.If TxtAcctName IsNot Nothing Then
15.         TxtAcctName.ClientEvents.OnBlur = sJsFunction
16.End If

 

Jscript

1.function BuscarAccCode(sender, eventArgs, rowIndex) {
2.            alert(sender.get_id() + ' index ' + rowIndex);
3.        }
4. 
5.function BuscarAccName(sender, eventArgs, rowIndex) {
6.            alert(sender.get_id() + ' index ' + rowIndex);
7.        }
Gilberto
Top achievements
Rank 1
Veteran
 answered on 30 Sep 2020
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?