Once I press 'Cancel' in the new screen, the Datagrid still shows one blank row. Once I refresh the page, it goes.
Your understanding of the behaviour is right. The DataGrid should not show an empty row after clicking cancel. Do you use the default cancel button?
Make sure that:
You can also try to use a custom cancel button, i.e. use a button to call a microflow. That microflow should contain a rollback (with refresh on true) and a close form activity.
The problem of empty row was existing due to one of refresh on client check boxes in one of microflows, but when i made sure that all check boxes are unchecked , it is resolved(I mean no empty row created in data grid). I mean I have to check all microflows (microflow of invoke button and if there is an event action(microflow) on the metaObject that supposed to be created or changed)
Maybe I don't understand your question completely, but it seems to be working as intended:
A microflow, when executed as you described, will first create an empty object (and store it in the database), then change a value (but, because you set commit to No, it won't store it in the database) and then show it in a dataview.
It should rollback once you hit either the "cancel" button or the "X" at the top (if it's a popup) and then show nothing in the datagrid. However, if you don't hit cancel or close the form and you surf to a datagrid, it will show an empty object there.
In other words, you shouldn't need a rollback action, just use the default cancel button.