HARD X-RAY EMISSION DURING FLARES AND PHOTOSPHERIC FIELD CHANGES