display err before hide panel