Newbie question - OpenAccess ORM and ODATA3

2 posts, 1 answers
  1. Luca
    Luca avatar
    3 posts
    Member since:
    Jan 2012

    Posted 11 Feb 2013 Link to this post

    I apologize now for probably obvious question, I just bought your products and today began my first application.

    Following several tutorials I started the first project to try to use Kendo Grid and openaccess ORM.

    Here's what I do:

    - Create a new project c # kendo ui for MVC
    - I choose to use OpenAccess domain model orm
    - I create a new domain class test with some property
    - Run "update db from model" and configure the connection

    So far so good, the database is created and works.

    Then I click "Add OpenAccess Service" and select "WCF .. - Odatav3" and finish.
    It creates the file "EntitiesModelService.svc."

    The problem is that if I click "View in browser" on that file to see if it works (as in yours tutorial) I always get an error

    Server Error in '/' Application ...
    The resource can not be found ...
    RequestedUrl: / EntitiesModelService.svc "

    What can I try? Please help me.
    Thanks in advance,
  2. Answer
    Boris Georgiev
    Boris Georgiev avatar
    190 posts

    Posted 12 Feb 2013 Link to this post

    Hello Luca,

    If you want to open the "EntitiesModelService.svc." file in browser, you should add in
    public static void RegisterRoutes(RouteCollection routes)
    method which is in "Global.asax.cs" file this line:
    This line will allow you to open .svc files which are outside of the MVC pattern - in your case "EntitiesModelService.svc." and "{*pathInfo}" at the end allows query strings to be ignored.

    Without this line, ASP.NET MVC would try to map all the requests to controllers and action. Having the "IgnoreRoute" method means the URL will not map the URL to a controller as per the default behavior

    I hope that helps.
    Kind regards,
    Boris Georgiev
    the Telerik team
    Q3'12 SP1 of OpenAccess ORM packs Multi-Table Entities mapping support. Check it out.
  3. UI for ASP.NET AJAX banner
Back to Top