Many existing distributed algorithms for network optimization problems often rely on the fact that, if the communications between subsystems are frequent enough, then the state of the network will converge to its optimum asymptotically. This approach will generally incur large communication cost. This work investigates the use of event-triggered communication schemes in distributed network optimization algorithms. Under event triggering, each subsystem broadcasts to its neighbors when a local ``error' signal exceeds a state dependent threshold. We use the network utility maximization (NUM) problem as an example to demonstrate our idea.We first present an event-triggered distributed barrier algorithm and prove its convergence. The algorithm shows significant reduction in the communication cost of the network. However, the algorithm suffers from several issues which limit its usefulness. We then propose two different event-triggered distributed NUM algorithms, the primal, and the primal-dual algorithm. Both algorithms are based on the augmented Lagrangian methods. We establish state-dependent event-triggering thresholds under which the proposed algorithms converge to the solutionof NUM. For the primal-dual algorithm, we consider scenarios when the network has data dropouts or transmission delay, and give an upper bound on the largest number of successive data dropouts and the maximum allowable transmission delay, while ensuring the asymptotic convergence of the algorithm. A state-dependent lower bound on the broadcast period is also given. Simulations show that all proposed algorithms reduce the number of message exchanges by up to two orders of magnitude when compared to existing dual decomposition algorithms, and are scale-free with respect to two measures of network size.We then use the optimal power flow (OPF) problem in microgrids as a nontrivial real-life example to demonstrate the effectiveness of event-triggered optimization algorithms. We develop an event-triggered distributed algorithm for the OPF problem and prove its convergence. We use the CERTS microgrid model as an example power system to show the effectiveness of our algorithm. The simulation is done in MATLAB/SimPower and shows that our algorithm solves the OPF problem in a distributed way, and the communication between neighboring subsystems is very infrequent.