OpenAccess Doesnt Work For Web Applications

5 posts, 0 answers
  1. Dean
    Dean avatar
    15 posts
    Member since:
    Mar 2009

    Posted 28 Mar 2009 Link to this post

    I've just purchased the Radcontrols collection, and so far it's not going too well.

    I've tried both ASP.NET MVC and regular ASP.NET web applications, and neither work with openaccess

    1) When you 'enable project to use ORM' selecting 'persistent classes' it skips the part of the wizard where it sets up a connection to a database, with the result that the openaccess section of web.config has empty child elements. (I only realise this step was missed when I successfully ran the wizard for a console application).

    2) I tried copying the 'app.config' sections from a test console applicaiton (that setup OK), but that didnt work.
    3) I've looked in the 'csproj' files for clues, but the section relating to openaccess seems OK.

    The whole thing is really clunky, and I keep getting exception errors in the wizards.

    Can anyone help me ? I've already spent too much time trying to get this going, maybe I should have stuck to simple old 'Linq to SQL classes.'

    Dean
  2. Dean
    Dean avatar
    15 posts
    Member since:
    Mar 2009

    Posted 29 Mar 2009 Link to this post

    The plot thickens

    When enabling a project for Openaccess, I get some clues when I go into 'Expert' mode.

    1) With a webste, everything is greyed out - therefore you cant set up openaccess for a website (can this really be true ???)
    2) With a class library, you can change stuff in expert mode, but the default setting is not to allow database updates, which makes wizard mode useless (you must enable this in expert mode to use openaccess)
    3) With winforms, you can change stuff in expert mode, and you are allowed to update the database by default - therefore this is the only type of project thats going to work va the wizard (?????).

    None of this makes any sense - I cannot work out any of the logic behind this. The documentation is particularly unhelpfull/

    Can someone tell me what I'm missing

    Dean
  3. DevCraft banner
  4. Zoran
    Admin
    Zoran avatar
    534 posts

    Posted 30 Mar 2009 Link to this post

    Hello Dean,

    The behavior you are experiencing is a completely regular one with OpenAccess. The reason this step is skipped is that OpenAccess does not store persistent classes into a web application/site but refers them from a ClassLibrary project. I suggest you have a look into these articles from our knowledge-base and online documentation that should really help you advancing with OpenAccess.

    You could also check the example from our code library that demonstrates OpenAccess in a real-world web-application.

    If you have any further questions please do not hesitate to contact us again in the future.

    All the best,
    Zoran
    the Telerik team

    Check out Telerik Trainer , the state of the art learning tool for Telerik products.
  5. Dean
    Dean avatar
    15 posts
    Member since:
    Mar 2009

    Posted 30 Mar 2009 Link to this post

    Thanks for the reply

    It's a shame that this information isnt made clear in the introductory documentation - it seems like an extremely important caveat to using this technology.

    Would have saved me a load of time and frustration.

    Thanks

    Dean
  6. Dimitar Kapitanov
    Admin
    Dimitar Kapitanov avatar
    632 posts

    Posted 31 Mar 2009 Link to this post

    Hi Dean,
    In our OpenAccess Tasks section we have the How to: Use a Data Model Defined in a Class Library which is exactly what you need for a kick-start. It is a goal-oriented article and should provide exactly the information you require. PLease shere with us what you think about the quality of content so far (documentation) and how to expose better this content (if you have ideas on that as well).

    All the best,
    Dimitar Kapitanov
    the Telerik team

    Check out Telerik Trainer , the state of the art learning tool for Telerik products.
Back to Top
DevCraft banner