The paper addresses the switching-like event-triggered control for uncertain networked control systems with time-varying delay under DoS attacks. First of all, to reduce the communication burden, a switching-like event-triggered mechanism is designed to automatically select the trigger condition according to whether the system is under DoS attacks, which have the advantage of reducing the number of data packets transmitted. Secondly, unlike the traditional assumption of time-varying delay, here it satisfies the condition that the probability is known, and combines the networked control systems to propose a novel time-delay system model, which can obtain a larger upper bound on the delay. Then, by using both the Lyapunov functional method and linear matrix inequality technique, we obtain sufficient conditions of uncertain networked control systems to achieve exponentially stable in the mean square sense. Furthermore, under the common limitations of the maximum continuous packet losses caused by the DoS attacks and delay, the stability criterion is derived, which can be used to estimate the communication parameters and security controller gain. Finally, through two simulation examples, the larger upper bound of time delay, less trigger times, faster convergence rate are obtained, which verify the validity of our theoretical analysis.