How to double click on a column header to edit mode

Hello All,

My requirement I had Webgrid in that each column contains 4 on each column once inserted loaded in view mode, once user click on any column header it should enable to edit mode.
once click column header and updated irrespective of records in each column ,once updated and again single click on header its get updated in DB and it should goes to view mode after column header single click or double click . I am using webgrid usinng MVc.

Kindly help me regarding this requirement.