Is help manual actual? Getting lost with DB connection

Thread is closed for posting
3 posts, 0 answers
  1. Wolfgang
    Wolfgang avatar
    98 posts
    Member since:
    Oct 2012

    Posted 22 Oct 2012 Link to this post


    it tried the following:

    Use the Database first scenario - hm.. first errors, Sybase connection needed to be configured manually, new did not work.

    Okay, with a little bit of guessing (would be easier if the format would be given) i had a connection to db.

    Second, try to create a consuming model.

    And now i'm completly stuck.

    My model name is as in example "EntitiesModel". If I look in definition  it is derived from OpenAccessContext:




    OpenAccessContext, IEntitiesModelUnitOfWork

    The Namespace is "TestConnection".

    If I try something like
    using (EntitiesModel dbContext = new EntitiesModel())
    { ...dbContext.SaveChanges();}

    there are no members to access the opencontext, only to the distinct persistent classes.

    How do i find the context?

  2. PetarP
    PetarP avatar
    754 posts

    Posted 24 Oct 2012 Link to this post

    Hi Wolfgang,

     Have you selected any entities to be generated in the step after you have specified the connection string? Basically if you have you should have some persistent classes generated together with the context and inside the context you should find some end points defined like that:

    public IQueryable<Product> Products
               return this.GetAll<Product>();
    Later on you can use those end points to access the data in the tables that correspond to them. If you are a newcomer in the OpenAccess world then I suggest you to have a look in our getting started section in the online documentation as it provides some easy to follow step by step guides on how to quickly get started with OpenAccess.

    All the best,
    the Telerik team
    Telerik OpenAccess ORM Meets ASP.NET Web API. Read more.
  3. Wolfgang
    Wolfgang avatar
    98 posts
    Member since:
    Oct 2012

    Posted 25 Oct 2012 Link to this post


    i used the quickstart to run into this error.

    The funny thing was, that new creation with same steps worked.
    I had a lot of persistent classes, so they weren't the missing thing.

    Only things like ".SaveChanges" method was not visible.
Back to Top