Wijmo UI for the Web
ensureControl Method
wijmo.grid Namespace > wijgrid type : ensureControl Method
Determines if the wijgrid must load data from a linked data source before rendering.
Moves the column widget options to the wijgrid options and renders the wijgrid. Use this method when you need to re-render the wijgrid and reload remote data from the datasource.
Syntax
$(function () {
    // Parameters
    var loadData; // Type:  bool
    
    $(".selector").wijgrid("ensureControl", loadData);
});
function ensureControl( 
   loadData : bool
) : void;

Parameters

loadData
Determines if the wijgrid must load data from a linked data source before rendering.
Example
// Adds a new row to the viewModel and refreshes the wijgrid
var len = viewModel.data().length;
viewModel.data.push(new Person({ ID: len, Company: "New Company" + len, Name: "New Name" + len }));
$("#element").wijgrid("ensureControl", true);
See Also

Reference

wijgrid type
wijgrid jQuery Widget