For any positive integer $x$, let $S(x)$ be the sum of the digits of $x$, and let $T(x)$ be $|S(x+2)-S(x)|.$  For example, $T(199)=|S(201)-S(199)|=|3-19|=16.$  How many values $T(x)$ do not exceed 1999?
1. **Understanding the Problem:**
   We need to find how many values \( T(x) \) do not exceed 1999, where \( T(x) = |S(x+2) - S(x)| \) and \( S(x) \) is the sum of the digits of \( x \).

2. **Analyzing Edge Cases:**
   We start by examining the edge cases where \( x \) is close to a power of 10. This is because the sum of the digits changes significantly when crossing a power of 10.

   - For \( x = 9 \):
     \[
     T(9) = |S(11) - S(9)| = |2 - 9| = 7
     \]
   - For \( x = 98 \):
     \[
     T(98) = |S(100) - S(98)| = |1 - 17| = 16
     \]
   - For \( x = 998 \):
     \[
     T(998) = |S(1000) - S(998)| = |1 - 26| = 25
     \]

3. **Generalizing the Pattern:**
   We observe that the significant changes occur when \( x \) is just below a power of 10. Specifically, if \( x \) has \( n \) digits all being 9 except the last digit being 8, then:
   \[
   x = 10^n - 2
   \]
   For such \( x \):
   \[
   S(x) = 9n + 8
   \]
   and
   \[
   S(x+2) = S(10^n) = 1
   \]
   Therefore,
   \[
   T(x) = |S(x+2) - S(x)| = |1 - (9n + 8)| = |1 - 9n - 8| = |9n + 7|
   \]

4. **Finding the Range:**
   We need \( |9n + 7| \leq 1999 \). This gives us:
   \[
   -1999 \leq 9n + 7 \leq 1999
   \]
   Solving for \( n \):
   \[
   -1999 - 7 \leq 9n \leq 1999 - 7
   \]
   \[
   -2006 \leq 9n \leq 1992
   \]
   \[
   -\frac{2006}{9} \leq n \leq \frac{1992}{9}
   \]
   \[
   -223.111 \leq n \leq 221.333
   \]
   Since \( n \) must be a non-negative integer:
   \[
   0 \leq n \leq 221
   \]

5. **Counting the Values:**
   The number of valid \( n \) values is:
   \[
   221 - 0 + 1 = 222
   \]

6. **Including the Case \( n = 0 \):**
   When \( n = 0 \), \( T(x) = 7 \), which is already included in our count.

Therefore, the total number of values \( T(x) \) that do not exceed 1999 is \( \boxed{222} \).