Object Data Source Empty

7 posts, 1 answers
  1. Peter
    Peter avatar
    12 posts
    Member since:
    Nov 2008

    Posted 28 Sep 2011 Link to this post


    I'm using the telerik reporting 2010 Q1.

    When adding a new report to my class library, I choose connection object data source which shows me all data objects in the library.

    After a while the wizard shows empty window and I cannot select these objects. They are still there.
    Tried rebuild still no go.

    The only way to get it back is to start new class library and my data objects are back.... again for a while.

    Has anyone had similiar problem?
  2. Answer
    Steve avatar
    10940 posts

    Posted 30 Sep 2011 Link to this post

    Hi Peter,

    We have not been contacted with such an inquiry before and could not reproduce such problem on our end.
    SqlDataSource Wizard searches for existing database connections in Server Explorer and in the configuration file of the current project. If you have a separate class library project for your reports, the wizard searches for connection strings only in the App.config file of that project. If you have your connection string specified in the Web.config file of another project, you need to copy it to the App.config file of the report class library as well, otherwise the wizard cannot discover it. The SqlDataSource Wizard simply uses the same design-time services that Visual Studio exposes to all designers. For instance, you can experience exactly the same inconsistent behavior if you add a typed DataSet and choose to store the connection string in the configuration file. Please try this to verify whether the problem is in Visual Studio or related to our product.
    Additionally can you elaborate what is your OS, Visual Studio version and target framework? Have you tried restarting Visual Studio to see if that helps?

    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. Alexei
    Alexei avatar
    1 posts
    Member since:
    Sep 2011

    Posted 04 Apr 2012 Link to this post

    Hi Peter
    I've reproduced the behavior. This happens when an assembly both in GAC and in local bin. Once you remove it from CAG, all members became available in SqlDataSource designer. Please check to be sure if this is the case...
  4. Greg
    Greg avatar
    2 posts
    Member since:
    Dec 2012

    Posted 03 Dec 2012 Link to this post


    THe original poster clearly said it was an "Object Datasource" NOT a "SqlDatasource". Furthermore, it appears the Object Datasource Wizard does not list all available referenced objects when used as a "Project Datasource".

  5. Steve
    Steve avatar
    10940 posts

    Posted 06 Dec 2012 Link to this post

    Hello Greg,

    Indeed there has been some misunderstanding in my previous reply, but on the other side it has been marked as answer from Peter.

    About the Project DataSources, we have verified the issue and it will be fixed for subsequent version of the product.

    All the best,
    the Telerik team

    HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

  6. Slava
    Slava avatar
    1 posts
    Member since:
    Jun 2016

    Posted 21 Jun 2016 Link to this post


    I'm using the Telerik HTML5 Report Viewer Page R2 2016(trial).

    I'm trying to create new report. For source I have chosen 'object data source', but selection list is empty. I read about assumptions:

    "If the desired type does not appear in the list, make sure the current project is built and all necessary project references are added. If you use the Visual Studio Report Designer have in mind that Visual Studio is a 32-bit application, so the designer is restricted to x86 mode even on x64 platforms, which prevents the ObjectDataSource Wizard from discovering any types from x64 assemblies. The solution is to use different platform configurations: for "Debug" builds it is best to use "Any CPU", while for "Release" builds you can use "x64" instead."

    But it doesn't help. In additional it works when I trying to create server control 'Telerik Report R2 2016 Wizard'.

  7. Stef
    Stef avatar
    3610 posts

    Posted 23 Jun 2016 Link to this post

    Hi Slava,

    In general, the purpose of the ObjectDataSource component is to provide data to the report in a declarative manner. The ObjectDataSource.DataSource should be the assembly qualified name or Type of the data access layer (class), where the reporting engine will use System.Reflection to create the instance of the class (by using its default constructor) and to execute its method specified by the ObjectDataSource.DataMember.
    In order the ObjectDataSource Wizard to discover types
    , the project must be built and types must be accessible. It is recommended to have separate projects for data access layer, UI and reports.

    If you are going to use the HTML5 MVC Viewer, please note that data objects are not transferred by the client to the server (the viewer does not use MVC model). The viewer submits short string formatted requests what resources to be prepared and rendered on the server, and then delivered by the Reporting REST service.

    Thus data models used by views cannot be used directly by reports. Instead you can save data on the server and then access it on requesting a report (via data source component).

    On a side note, if you are using the Standalone Report Designer, the ObjectDataSource component can be used with external assemblies extending the designer's functionality - Extending Report Designer.

    In order to provide you more accurate suggestions, please elaborate on the issue with screenshots and examples of the data access layer you want to use.

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top