The gnats can be a sign of a larger problem. Constantly soggy soil and stagnant air. Their presence can indicate the soil is staying too wet. Better watering practices can help. Allowing the soil to dry down (like the top inch) a bit helps control them as well as being better for the tree. If the tree is inside (and Chinese elms can only limp along inside before they eventually fade away), these problems are worsened.