Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7043679
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T02:19:09+00:00 2026-05-28T02:19:09+00:00

I am using the Matisse DB with .NET bindings to fetch objects from the

  • 0

I am using the Matisse DB with .NET bindings to fetch objects from the database and populate a WPF datagrid. The database has generated me a LINQ context which I can use to retrieve objects from the database. I am trying to simply bind the contents of an object to a WPF grid, something I can do with ADO.NET/MySQL with no issues. The following code shows the issue I have:

    private void displayManagersConsole()
    {
        //This Works, prints out to console
        conn.Open();
        LinqExample linq = new LinqExample(conn);
        var query = (from m in linq.Managers select m);
        foreach (var manager in query)
        {
            Console.WriteLine(manager.FirstName);
        }
        conn.Close();
    }

    private void displayManagersWPF()
    {
        //This fails
        conn.Open();
        LinqExample linq = new LinqExample(conn);
        peopleGrid.ItemsSource = linq.Managers;
        conn.Close();
    }

As you can see, I have two methods. The first method opens a connection, gets info from the object and then closes the connection. This works without problem and the connection closes fine. However when I try the second method it throws the following exception:

MATISSE-E-NOTRANORVERSION, Attempted to access objects without a transaction or version access

I have read extensively through the documentation and can not explain this. The strange thing is, if i remove the conn.Close(); after assigning the itemssource to my datagrid, it works fine! It seems that even after the itemssource has been assigned, it is somehow caching it, such that the datagrid needs the connection to be open. I get this behaviour only when using wpf components, yet all console queries work without problem. I have also tried iterating in a foreach loop and adding each Manager object to the Items collection of the datagrid, only to get the same exception.

I have tried forcing the binding as one way, one time. Have tried messing with transactions. I even put in a connection open and connection close button and tried to follow whats happening, but I simply cannot close the connection if the itemssource is assigned.

If anyone could help, would really appreciate it.
Thanks,
Mike

EDIT: This seems to work
Working
The solution I used was to just get the columns I wanted. Therefore it seems likely it is relating to lazy loading/eager loading. The documentation does not however seem to comment on how this can be modified. Thanks for input, I will use this:

    private void displayManagersWPF()
    {
        conn.Open();
        conn.StartTransaction();
        Example db = new Example(conn);
        peopleGrid.ItemsSource = (from m in db.Managers
                                  select new
                                      {
                                          m.FirstName,
                                          m.LastName,
                                          m.Title
                                      }
                                 );
        conn.Close();
    }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T02:19:10+00:00Added an answer on May 28, 2026 at 2:19 am

    var linq = from i in dc.Managers select i.FirstName;

    peopleGrid.ItemsSource = linq.ToList();

    dc.Connection.Close();

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a dilemma; developing desktop application using Matisse or Jigloo.. Matisse has this
Using ASP.NET MVC there are situations (such as form submission) that may require a
Using C# .NET 3.5 and WCF, I'm trying to write out some of the
Using VS2008, C#, .Net 2 and Winforms how can I make a regular Button
Using C#, I need a class called User that has a username, password, active
Using android 2.3.3, I have a background Service which has a socket connection. There's
Using WPF/PRISM I want to log my messages through ILoggerFacade to my GUI (A
Using mercurial, I've run into an odd problem where a line from one committer
Using php/html, I want to retrieve email addresses (plus other information) from MySQL and
Using emacs on Ubuntu 11.10. I want to connect to a SQL Server database

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.