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

  • Home
  • SEARCH
  • 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 60735
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T18:12:31+00:00 2026-05-10T18:12:31+00:00

I had a problem that was partially solved. To explain it quickly : I

  • 0

I had a problem that was partially solved. To explain it quickly : I have a grid binded to a complex object that require to be serialized. When the object is build back from the serialization, event like on the grid doesn’t refresh the table display. Someone told me to rebuild the event once unserialize, it works! But the event that refresh the grid doesn’t seems to fire at all.

I had to build an event from my complex object that told me that something change inside. From this event I added this code :

this.bindingSource1.ResetBindings(false); 

The problem is the grid is flipping and the user doesn’t have a good feeling (rows are moving up and down and than stop).

How can I reset the binding without having this kind of flipping? How can I solve the original problem? (This will solve automaticly everything).

Update

Here is an example that do exactly the same behavior:

Create a class:

[Serializable()] class BOClient : INotifyPropertyChanged, IDataErrorInfo {     private string name;     private int len;     public string Name     {         get { return name; }         set { name = value;         this.len = name.Length;         if (this.PropertyChanged !=null)             this.PropertyChanged(this, new PropertyChangedEventArgs('Name'));         }     }      public int Len     {         get { return this.len; }     }      public BOClient(string name)     {         this.Name = name;     }      #region INotifyPropertyChanged Members      public event PropertyChangedEventHandler PropertyChanged;      #endregion      #region IDataErrorInfo Members      public string Error     {         get { return ''; }     }      public string this[string columnName]     {         get { return ''; }     }      #endregion } 

Now, create a form with a BindingSource call ‘bindingSource1’ and go use the class as datasource. Create a grid and bind the grid to the bindingsource1.

In that form use this code in the load :

 private void Form1_Load(object sender, EventArgs e)     {         BindingList<BOClient> listClient = new BindingList<BOClient>();         listClient.Add(new BOClient('P1'));         listClient.Add(new BOClient('P2'));         listClient.Add(new BOClient('P3'));          //using (MemoryStream mem = new MemoryStream())         //{         //    BinaryFormatter b1 = new BinaryFormatter();          //    try         //    {         //        b1.Serialize(mem, listClient);         //    }         //    catch (Exception ez)         //    {         //        MessageBox.Show(ez.Message);         //    }             //    BinaryFormatter b2 = new BinaryFormatter();          //    try         //    {         //        mem.Position = 0;         //        listClient = (BindingList<BOClient>)b2.Deserialize(mem);         //    }         //    catch (Exception ez)         //    {         //        MessageBox.Show(ez.Message);         //    }          //}           this.bindingSource1.DataSource = listClient;     } 

I put the serialization process in comment BECAUSE it seems that it do the same weird behavior without it… now start the application. Change a name of a client. Example ‘p1’ for ‘New name’ and click the cell under the changed one. You will see the ‘len’ column NOT changing. BUT if you click the cell that has the len you will see the number changing to the right value.

Any one have an idea why?

  • 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. 2026-05-10T18:12:31+00:00Added an answer on May 10, 2026 at 6:12 pm

    I have solve this problem by adding in the BindingList (by inheritance) a method [OnDeserialization] within I added code that add event on the OnListChange. This way when 1 property change, the whole line is refreshed.

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

Sidebar

Ask A Question

Stats

  • Questions 124k
  • Answers 124k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Are you running on OS 3.0? I saw the same… May 12, 2026 at 1:19 am
  • Editorial Team
    Editorial Team added an answer It looks like you need to register Apache::Session::Memcached with Apache::Session::Wrapper,… May 12, 2026 at 1:19 am
  • Editorial Team
    Editorial Team added an answer Use DATENAME or DATEPART: SELECT DATENAME(dw,GETDATE()) -- Friday SELECT DATEPART(dw,GETDATE())… May 12, 2026 at 1:19 am

Related Questions

Greetings, I'm in the middle of writing a Flash application which has multilingual support.
I'm using jQuery UI's draggable and droppable libraries in a simple ASP.NET proof of
Our web page is only available internally in our company and we am very
So I have been pulling my hair out troubleshooting this bug I have been

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.