Iron in the vicinity of compasses results in magnetic deviations. ADCPs mounted on steel buoyancy devices and deployed on seven moorings on the East Greenland outer shelf and upper slope from 2007 to 2008 suffered from severe magnetic deviations of $>$90$^\circ$ rendering the ADCP data useless without a compass correction. The effects on the measured velocities, which may also be present in other oceanic velocity measurements, are explained. On each of the moorings, velocity measurements from a different instrument which was assumed not to be affected by magnetic deviation are overlapping in space and time with the compromised ones. A method is described to determine the magnetic compass deviation from the compromised and uncompromised velocity measurements and the compromised compass headings. The method depends on the assumption that at least one instrument per mooring is not compromised. With this method, the magnetic deviation as well as the originally compromised velocity records can be corrected. The method is described in detail and a MATLAB(R) script implementing the method is supplied. The success of the method is demonstrated for one of the moorings.