Fixed the grid refresh issue