A device and to an associated method for a diagnostic apparatus. A housing unit can be aligned by way of a securing unit which is connected to the housing and it can be controlled in such a way that the diaphragm unit which is connected to the x-ray source and is arranged in the housing unit can be aligned in accordance with a specified position.