I start a new Visual Web Part project, add an SPDataSource to any Sharepoint list, and then add a telerik control, and map the control to the datasource and VS freezes. This happens with the radlistbox, radgrid, and radlistview at a minimum. I've used RadMenu and several other controls in my Sharepoint 2010 environment without issues. Also, if I use a regular grid control and bind it to SPDataSource there's no problems.
I'm just simply adding it this way.
Any ideas why this would be happening? Can you test it out?
I'm just simply adding it this way.
<SharePoint:SPDataSource ID="SPDataSource1" runat="server" DataSourceMode="List" UseInternalName="true" SelectCommand="<View></View>"> <SelectParameters> <asp:Parameter Name="WebUrl" DefaultValue="/subsite/" /> <asp:Parameter Name="ListName" DefaultValue="Contacts" /> </SelectParameters> </SharePoint:SPDataSource>
Any ideas why this would be happening? Can you test it out?
5 Answers, 1 is accepted
0
Hello Clint,
Pleas note that binding RadGrid control to SPDataSource explicitly is not a supported scenario. You should use the RadGrid WebParts and bind the WebParts to the specific DataSource through the provided designer. Please refer to the following online examples.
Kind regards,
Maria Ilieva
the Telerik team
Pleas note that binding RadGrid control to SPDataSource explicitly is not a supported scenario. You should use the RadGrid WebParts and bind the WebParts to the specific DataSource through the provided designer. Please refer to the following online examples.
Kind regards,
Maria Ilieva
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!
0
Clint
Top achievements
Rank 1
answered on 23 Jul 2011, 01:09 AM
Though the web parts are great (they're very quick, easy, and stylish), I'm finding I need the ability to connect to other web parts or setup a parent/child relationship between a grid/listview and other controls.
The easiest way I've found to hit a sharepoint list with radgrid is to use a needdatasource event
After that, uncheck auto-generate columns and manually add/create your structure.
I've given up on spdatasource, even in code, as the parsespviewfieldsintodatacolumns seems to stare back at me all the time. ListView and most other controls seem to be more forgiving.
The easiest way I've found to hit a sharepoint list with radgrid is to use a needdatasource event
protected
void
RadGrid1_NeedDataSource(
object
source, Telerik.Web.UI.GridNeedDataSourceEventArgs e)
{
SPSite oSite =
new
SPSite(
"http://site"
);
SPWeb oWeb = oSite.OpenWeb();
SPList supplies = oWeb.Lists[
"Supplies"
];
RadGrid1.DataSource = supplies.Items.GetDataTable();
}
After that, uncheck auto-generate columns and manually add/create your structure.
I've given up on spdatasource, even in code, as the parsespviewfieldsintodatacolumns seems to stare back at me all the time. ListView and most other controls seem to be more forgiving.
0
Hello Clint,
If you are looking for parent/child relationship mechanism, you may consider utilizing the hierarchy feature of the SPRadGrid web part, available as part of the Telerik SharePoint Acceleration Kit CTP (if applicable for your scenario).
By the way, in case you implemented some kind of connectivity/dependencies between web parts using our AJAX controls, feel free to post them in this forum thread. They can be useful to other Telerik community members and we will reward you with some Telerik points for sharing your solution (which can be used as a discount for future upgrades/purchases of our components).
Best regards,
Sebastian
the Telerik team
If you are looking for parent/child relationship mechanism, you may consider utilizing the hierarchy feature of the SPRadGrid web part, available as part of the Telerik SharePoint Acceleration Kit CTP (if applicable for your scenario).
By the way, in case you implemented some kind of connectivity/dependencies between web parts using our AJAX controls, feel free to post them in this forum thread. They can be useful to other Telerik community members and we will reward you with some Telerik points for sharing your solution (which can be used as a discount for future upgrades/purchases of our components).
Best regards,
Sebastian
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!
0
Clint
Top achievements
Rank 1
answered on 01 Aug 2011, 03:13 AM
Any ideas on this error? It seems that I get this frequently when binding datasources to grid.... what am I forgetting?
[NotImplementedException: The method or operation is not implemented.]
Telerik.Web.UI.RadGrid.ParseSPViewFieldsIntoDataColumns(T firstObject) +39
Telerik.Web.UI.GridDataTableFromEnumerable.ParseSPListItemProperties(T firstObject) +102
Telerik.Web.UI.GridResolveEnumerable.ParseProperties() +549
Telerik.Web.UI.GridResolveEnumerable.Initialize() +16
Telerik.Web.UI.GridResolveEnumerable.EnsureInitialized() +28
Telerik.Web.UI.GridEnumerableFromDataView..ctor(GridTableView owner, IEnumerable enumerable, Boolean CaseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +246
Telerik.Web.UI.GridDataSourceHelper.CreateGridEnumerable(GridTableView owner, IEnumerable enumerable, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +235
Telerik.Web.UI.GridDataSourceHelper.GetResolvedDataSource(GridTableView owner, Object dataSource, String dataMember, Boolean caseSensitive, Boolean autoGenerateColumns, GridColumnCollection presentColumns, String[] additionalField, Boolean retrieveAllFields, Boolean enableSplitHeaderText) +514
Telerik.Web.UI.GridTableView.get_ResolvedDataSource() +264
Telerik.Web.UI.GridTableView.CreateChildControls(IEnumerable dataSource, Boolean useDataSource) +42
System.Web.UI.WebControls.CompositeDataBoundControl.PerformDataBinding(IEnumerable data) +72
System.Web.UI.WebControls.DataBoundControl.OnDataSourceViewSelectCallback(IEnumerable data) +147
System.Web.UI.WebControls.DataBoundControl.PerformSelect() +261
Telerik.Web.UI.GridTableView.PerformSelect() +23
Telerik.Web.UI.GridTableView.DataBind() +363
Telerik.Web.UI.RadGrid.DataBind() +73
Black.Modules3.Modules3UserControl.RefreshData() +1652
Black.Modules3.Modules3UserControl.Page_Load(Object sender, EventArgs e) +89
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42
System.Web.UI.Control.OnLoad(EventArgs e) +132
System.Web.UI.Control.LoadRecursive() +66
System.Web.UI.Control.AddedControl(Control control, Int32 index) +350
Black.Modules3.Modules3.CreateChildControls() +155
System.Web.UI.Control.EnsureChildControls() +146
System.Web.UI.Control.PreRenderRecursiveInternal() +61
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Control.PreRenderRecursiveInternal() +224
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3394
0
Hello Clint,
From the presented error I noticed that you are binding the RadGrid to SP list using the NeedDataSource event. However as I previously mentioned this explicit binding is not a supported functionality in the current version of the control. Please use the designer to bind the Grid to the required database.
All the best,
Maria Ilieva
the Telerik team
From the presented error I noticed that you are binding the RadGrid to SP list using the NeedDataSource event. However as I previously mentioned this explicit binding is not a supported functionality in the current version of the control. Please use the designer to bind the Grid to the required database.
All the best,
Maria Ilieva
the Telerik team
Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.