new version problem

2 posts, 1 answers
  1. Hans
    Hans avatar
    49 posts
    Member since:
    Jul 2010

    Posted 17 Mar 2011 Link to this post

    Hi !

    After I installed the new version of ORM I have a problem.
    So I have a table with 2 field ID and Description.
    I have this code

     

    public static IList<PA_JobType

    > GetPaJobTypeList()

     

     

    {

     

     

     

    IList<PA_JobType> listObj;

     

     

     

    using (WoDbContext localContext = new WoDbContext

    ())

     

     

    {

     

     

     

    IQueryable<PA_JobType> tempListObj = (from c in localContext.PA_JobTypes select

    c).OrderBy(f => f.JobType);

     

     

    listObj = tempListObj.ToList();

     

    }

     

     

     

    return

    listObj;

     

     

    }

     



    Before this coee run perfect. I as able to bind this list to a control to show id and description.
    Now, after ORM upgrade, I get this error:
    Description = '(new System.Collections.Generic.Mscorlib_CollectionDebugView<WO_BaseClassLibrary.PA_JobType>(listJobType)).Items[0].Description' threw an exception of type 'Telerik.OpenAccess.Exceptions.InvalidOperationException'

    base {Telerik.OpenAccess.OpenAccessException} = {"The 'IObjectScope' is already closed"}

    Why I get this error ?

    Regards
    Hans









  2. Answer
    Damyan Bogoev
    Admin
    Damyan Bogoev avatar
    581 posts

    Posted 21 Mar 2011 Link to this post

    Hello Hans,

    Firstly I want to apologize for the inconvenience caused. We have located the cause for the problem and fixed it. The fix will be included in the next internal build of the product which is expected later this week.
    If you cannot wait for the build, you could use a long-running context in the helper class in order to avoid this behavior.
    We will let you know once the new build is available.
    You could find your Telerik points updated.

    Best wishes,
    Damyan Bogoev
    the Telerik team
  3. DevCraft banner
Back to Top