Got round this problem by adding <arg value="/nowin32manifest " /> in the
csc task