Closed operator and dense range

I am trying to find an easier characterization for the resolvent set of a closed operator. I know that if $T\colon X\to X$ is a bounded linear operator in a Banach space $X$, then $\lambda\in\rho(T)$ if and only if $\lambda I - T$ is bijective, due to the open mapping theorem. Is there a similar characterization when $T$ is only closed and not necessarily defined on the whole space?

My setting is the following: I have a Banach space $X$, a closed linear operator $T\colon D(T)\subset X\to X$ (which I can assume to be densely defined, if necessary). I would like to prove something like $$\lambda\in\rho(T) \Longleftrightarrow \lambda I - T \text{ is bijective},$$ but I don't know if this is true.

$\cdot$ It is clear that $\Longrightarrow$ is true;

$\cdot$ Now suppose $\lambda I - T$ is bijective. Then it has an inverse $(\lambda I -T)^{-1}\colon \text{Range }(T)\to D(T)$. Since $T$ is closed, also $(\lambda I -T)^{-1}$ is closed and hence $\text{Range}(T)$ is closed. If I can prove that $\text{Range}(T)$ is dense in $X$, then by the Closed Graph Theorem it must be continuous. But is this true? Maybe not in general... and what if $T$ is assumed to be densely defined?

Edit: I have just noticed that my question is perhaps a bit silly, isn't it? To say $\lambda I -T\colon D(T)\subset X\to X$ is bijective, means in particular that it is surjective and so the domain of $(\lambda I - T)^{-1}$ is the whole $X$, right? So $(\lambda I - T)^{-1}\colon X\to X$ is a closed operator, hence continuous by the Closed Graph Theorem. So $\lambda\in\rho(T)$.
• Yes, the closed graph theorem works. If $T : \mathcal{D}(T)\subset X\rightarrow X$ is closed and densely-defined, and if $T-\lambda I$ is injective and surjective, then $(T-\lambda I)^{-1}$ is closed and everywhere defined, which makes it bounded. – DisintegratingByParts May 7 '18 at 20:31
• Actually, @DisintegratingByParts, do we need $T$ to be densely defined? For which part of the proof? – user194469 May 8 '18 at 8:17