finally fixed the bug in the resultgrid