The box mesh and Sensitive Detector

Dear all,
I want to create a box mesh using G4PVPlacement and CopyNumber index. After that, I must score the deposited energy for each mesh element using the Sensitive Detector. Can anyone help me, please? Or give me an example. Thanks in advance.