A derelict building which has proved a magnet for anti-social behaviour is finally set for transformation.