Using Liouville's Theorem we can show that $e^{-x^2}$ does not have an elementary antiderivative.
First assume that $\int e^{-x^2}dx=F(x)$ is an elementary antiderivative, i.e. $F(x)$ is a finite combination of elementary functions (polynomials, exponentials, logarithms, trigonometric functions, etc), such that
$$F'(x) = e^{-x^2}.$$
Liouville’s Theorem says that if $F(x)$ exists and is elementary, then it must have the form
$$F(x) = R(x) + \sum_i c_i \ln(g_i(x)),\tag{1}$$
where $R(x)$ is a rational function, $c_i$ are constants, and $g_i(x)$ are algebraic functions. Taking the derivative,
$$R'(x) + \sum_i c_i \frac{g_i'(x)}{g_i(x)}=F'(x)=e^{-x^2}.\tag{2}$$
But $e^{-x^2}$ is transcendental by the Lindemann–Weierstrass theorem, i.e. it does not satisfy any algebraic equation with coefficients in $\mathbb{Q}(x)$ as required by (2). Hence, (1) cannot possibly be expressed as a combination of rational functions and logarithmic terms.
Therefore, $\int e^{-x^2}dx$ cannot be expressed in terms of elementary functions.
For your other question to prove that an equation does not have elementary solution, I would probably try to prove that e.g. $xe^x$ or $\cos(x)-x$ is transcendental in that it does not satisfy any algebraic equation with coefficients in $\mathbb{Q}(x)$, again probably making use of the Lindemann–Weierstrass theorem.