Many believe that the sap in dock leaves contain an antihistamine, which can help to soothe the stinging sensation. It has also been suggested that the cooling sensation of the sap evaporating from the skin affected can also relieve some of the stinging sensation.
I used to always hunt for dock leaves when I got stung by nettles to stop itching