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 6941671
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T12:54:57+00:00 2026-05-27T12:54:57+00:00

I originally thought this was a INotifyPropertyChanged/Binding issue because I’m not sure how to

  • 0

I originally thought this was a INotifyPropertyChanged/Binding issue because I’m not sure how to debug the silverlight part. So I had to put a messagebox in a foreach loop and view the values after the data returned that way. It turns out that I’m having trouble getting the updated data from the service. I use the service to do some updates to data on the server and when it gets back call to reload the data. This part of the service is returning the correct data (I verified using a breakpoint so I could look at the data result was holding). But the silverlight side is not getting the right data. Here is the relevant code.

public IQueryable<OurClass> GetItems(string condition)
{
    var result   = from items in context.OurClass 
                   where item.value == condition  
                   select item;

    return result; //had my breakpoint here and the values were the correct updated values
}

/

Context.Load<OurClass>(Context.GetItemsQuery(condition)).Completed += new EventHandler(Context_LoadCompleted);

/

private void Context_LoadCompleted(object sender, EventArgs e)
{
    IEnumerable<OurClass> result = ((LoadOperation<OurClass>)sender).Entities;
    //This is where I put a MessageBox to view the returned results and the data was different
    //than what was contained in the other result
}

Any ideas what could cause this? What should I look at next?

EDIT:

Some example data is OurClass.OurProperty will equal “Test” on the server side but once it is received on the client it will equal “Development” which was the old value. The IEnumerable will hold the newly added records and not have the deleted ones. Any that previously existed will contain the old property values and not the new values.

  • 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-27T12:54:58+00:00Added an answer on May 27, 2026 at 12:54 pm

    The solution was that I needed to add the parameter LoadBehavior.RefreshCurrent to the query call. So this:

    Context.Load<OurClass>(Context.GetItemsQuery(condition)).Completed += new EventHandler(Context_LoadCompleted); 
    

    Needed to be this:

    Context.Load<OurClass>(Context.GetItemsQuery(condition), LoadBehavior.RefreshCurrent, true).Completed += new EventHandler(Context_LoadCompleted);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Originally: I thought this was a circular reference problem........turns out it's not. The problem
I originally thought this was a WordPress issue - but realize after hours of
(function() { //do stuff })(); EDIT: I originally thought this construct was called a
I thought I would rewrite this question (same iteration). The original was how to
Originally I thought to ask if there would be an easy way to provide
Originally I had a design problem where I needed five subclasses of a superclass,
Originally I had two tables in my DB, [Property] and [Employee]. Each employee can
Originally posted on Server Fault , where it was suggested this question might better
I originally asked this question on RefactorMyCode , but got no responses there... Basically
I thought this could've been a common question, but it has been very difficult

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.