This paper designs a continuous‐time algorithm with event‐triggered communication (ETC) for solving a class of distributed convex optimization problems with a metric subregularity condition. First, we develop an event‐triggered continuous‐time optimization algorithm to overcome the bandwidth limitation of multi‐agent systems. Besides, with the aid of Lyapunov theory, we prove that the distributed event‐triggered algorithm converges to the optimum set with an exact linear convergence rate, without the strongly convex condition. Moreover, we provide the discrete version of the continuous‐time algorithm and show its exact linear convergence rate. Finally, we give a comparison example to validate the effectiveness of the designed algorithm in communication resource saving.