Data Refreshing in FarPoint Grid - WinForm

Posted by: wedant on 8 September 2017, 1:06 pm EST

  • Posted 8 September 2017, 1:06 pm EST

    Hi,<br><br>I am using 3.0.2005.2005 Version of FarPoint WinForm Control.<br>In the grid I have set Datasource as object of an IList class type.<br>In runtime I am changing value of particular cells and calculating value of particular cell based on entered value. Without calling Invalidate() method grid not getting refreshed.<br>There is any option to get same result without calling Invalidate() method.<br><br><br>Code Sample:<br><font size="2">if ( e.Column == this.grdLaborPlanning.GetColumnIndexFromKey ( COLUMN_ST ) )<br>                {<br>                    this.m_OrderBookings [ modelRow ].ST = Convert.ToInt32 ( e.EditingControl.Text );<br>                }<br>                else if ( e.Column == this.grdLaborPlanning.GetColumnIndexFromKey ( COLUMN_OT ) )<br>                {<br>                    this.m_OrderBookings [ modelRow ].OT = Convert.ToInt32 ( e.EditingControl.Text );<br>                    this.m_OrderBookings [ modelRow ].ST = ( this.m_OrderBookings [ modelRow ].Duration ) - ( this.m_OrderBookings [ modelRow ].OT + this.m_OrderBookings [ modelRow ].DT );<br>                }<br><br>                else if ( e.Column == this.grdLaborPlanning.GetColumnIndexFromKey ( COLUMN_DT ) )<br>                {<br>                    this.m_OrderBookings [ modelRow ].DT = Convert.ToInt32 ( e.EditingControl.Text );<br>                    this.m_OrderBookings [ modelRow ].ST = ( this.m_OrderBookings [ modelRow ].Duration ) - ( this.m_OrderBookings [ modelRow ].OT + this.m_OrderBookings [ modelRow ].DT );<br>                }</font><br>this.grdLaborPlanning.Invalidate ( e.EditingControl.Region );<br><br><br>Thanks and Regards<br>
    Wedant<br><br>
  • Replied 8 September 2017, 1:06 pm EST

    <P>Wedant,</P>
    <P>You would need to implement the IBindingList interface to have the list automatically update the controls bound to it. Take a look at the following <A HREF="/Forums/forums/thread/10930.aspx">thread</A> for code on how to implement this.</P>
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels