Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
175
Databinding on the fly for Windows UltraGrid
posted

How can I databind with a new list every time I click a button (refresh the grid with the new data).

  • 29105
    Verified Answer
    Offline posted

    Hello Joy,

    In your button's click event you can handle the following code to populate your grid by either using the datasource or setdatabinding properties. Here is an example:


    private void ultraButton1_Click(object sender, EventArgs e)
    {
    BindingList<Test> binding = new BindingList<Test>();
    ...
    ...
    ultraGrid.SetDataBinding(binding, null);
    }