Tool (10; 30) having a tool element (22; 32) for treating a workpiece (3; 4), a sensing device (233; 33) for sensing the position of the tool (10; 30) and/or of the tool element (22; 32) in space relative to a surface of the workpiece (3; 4) and to an axis of a screw or of a rivet, and a control device (23; 34) which is designed to evaluate the value, sensed by the sensing device (233; 33), relative to the surface of the workpiece (3; 4) and to the axis of the screw or of the rivet, and which is designed to control the tool (10; 30) depending on whether the result of the evaluation lies in a predetermined tolerance range about a predetermined value, wherein the control device (23; 34) is designed to allow the start of a treatment of the workpiece (3; 4) with the tool element (22; 32) when the result of the evaluation lies in the predetermined tolerance range, and/or in the event of a known misalignment of the tool element (22; 32) with respect to the screw or the rivet, wherein the control device (23; 34) is designed to check whether the values that have been sensed by a position sensor of the tool (10; 30) and/or a force sensor of the tool (10; 30) during the treatment of the workpiece (3; 4) with the tool element (22; 32) lie within predefined limits or not, and wherein the control device (23; 34) is designed to evaluate the treatment of the workpiece (3; 4) with the tool element (22; 32) as "good" or "okay" when the values sensed by the position sensor and/or the force sensor lie within the predefined limits, and to evaluate the treatment of the workpiece (3; 4) with the tool element (22; 32) as "poor" or "not okay" when one of the values does not lie within the predefined limits. a tool element (22; 32) for treating a workpiece (3; 4), a sensing device (233; 33) for sensing the position of the tool (10; 30) and/or of the tool element (22; 32) in space relative to a surface of the workpiece (3; 4) and to an axis of a screw or of a rivet, and a control device (23; 34) which is designed to evaluate the value, sensed by the sensing device (233; 33), relative to the surface of the workpiece (3; 4) and to the axis of the screw or of the rivet, and which is designed to control the tool (10; 30) depending on whether the result of the evaluation lies in a predetermined tolerance range about a predetermined value, wherein the control device (23; 34) is designed to allow the start of a treatment of the workpiece (3; 4) with the tool element (22; 32) when the result of the evaluation lies in the predetermined tolerance range, and/or in the event of a known misalignment of the tool element (22; 32) with respect to the screw or the rivet, wherein the control device (23; 34) is designed to check whether the values that have been sensed by a position sensor of the tool (10; 30) and/or a force sensor of the tool (10; 30) during the treatment of the workpiece (3; 4) with the tool element (22; 32) lie within predefined limits or not, and wherein the control device (23; 34) is designed to evaluate the treatment of the workpiece (3; 4) with the tool element (22; 32) as "good" or "okay" when the values sensed by the position sensor and/or the force sensor lie within the predefined limits, and to evaluate the treatment of the workpiece (3; 4) with the tool element (22; 32) as "poor" or "not okay" when one of the values does not lie within the predefined limits.