Posted 11 January 2018, 1:16 am EST
Hello,
Please look into below HTML
- When there is no data on data i set that
$scope.isEmptyGrid=true
.2. In this case when i make
$scope.isEmptyGrid=false
, That time all grid class property set to width and height to zero.3. Again i reload the grid its showing.
<div id="grid1" ng-show="!isEmptyGrid"></div>
<div id="EmptySchedular" ng-show="isEmptyGrid" class="text-center" style="margin-top:15%;">
<span style="padding:3px;">
No Record found
</span>
</span>
</div>
I used
dataView.invalidate();
``` and ```
dataView.destroy();
And also i try to use
document.querySelector('#grid1').focus();
was not applying
And my code is below
dataView = new GC.Spread.Views.DataView(document.getElementById('grid1'), $scope.Data, columns,
new GC.Spread.Views.Plugins.GridLayout(
{
allowSorting: false,
showColHeader: true,
showRowHeader: false,
allowResizing: true,
selectionMode: 'single',
showToolPanel: false,
allowColumnReorder: true,
allowCellMerging: true,
//grouping: grouping
}));
dataView["rowClick"].addHandler(rowClickFun);
dataView["rowDbClick"].addHandler(rowDbClickFun);
dataView['columnReorder'].addHandler(columnReorderFun);
dataView['columnChanged'].addHandler(columnChangedFun);
dataView.invalidate();
document.querySelector('#grid1').focus();
dataView.setSelections(token.ctRow, 0);
Help me to get solution.
Thanks,
Arulventhan NP