Suppose we have a random sample $(X_1,..,X_n)$ from a Uniform$(2,2\theta)$ distribution. We're interested in $\mathbb{E}[X_{(n)}]$, the expectation of the maximum order statistic. I found that the CDF of $X_{(n)}$ is,
$$ F_{X_{(n)}}(x) = \left(\frac{x-2}{2\theta-2}\right)^n \;\;\;\; 2 < x < 2\theta$$
The corresponding pdf is then,
$$ f_{X_{(n)}}(x) = \frac{n(x-2)^{n-1}}{(2\theta-2)^n} \;\;\;\; 2 < x < 2\theta $$
I've been trying to calculate the expectation using two methods,
$$ \mathbb{E}[X_{(n)}] = \int\limits_2^{2\theta}xf_{X_{(n)}}(x)dx \;\;\;\;\;\; \& \;\;\;\;\;\; \mathbb{E}[X_{(n)}] = \int\limits_2^{2\theta}(1-F_{X_{(n)}}(x))dx $$
However, I'm getting different results,
$$ \int\limits_2^{2\theta}xf_{X_{(n)}}(x)dx = \int\limits_2^{2\theta}x\frac{n(x-2)^{n-1}}{(2\theta-2)^n}dx = \frac{2\theta n + 2}{n+1} $$ $$ \int\limits_2^{2\theta}(1-F_{X_{(n)}}(x))dx = \int\limits_2^{2\theta}\left(1-\left(\frac{x-2}{2\theta-2}\right)^n\right)dx = \frac{2\theta n - 2n}{n+1}$$
Am I not applying the formula correctly? Under what conditions (other than $X$ being nonnegative) does the formula, $\mathbb{E}[X] = \int\limits_0^\infty(1-F_X(x))dx$, apply?