Let $(X,d,mu)$ be a metric measure space satisfying a $Q$-doubling condition, $Q>1$, and an $L^2$-Poincar{e} inequality. Let $mathscr{L}=mathcal{L}+V$ be a Schrodinger operator on $X$, where $mathcal{L}$ is a non-negative operator generalized by a Dirichlet form, and $V$ is a non-negative Muckenhoupt weight that satisfies a reverse Holder condition $RH_q$ for some $qge (Q+1)/2$. We show that a solution to $(mathscr{L}-partial_t^2)u=0$ on $Xtimes mathbb{R}_+$ satisfies the Carleson condition, $$sup_{B(x_B,r_B)}frac{1}{mu(B(x_B,r_B))} int_{0}^{r_B} int_{B(x_B,r_B)} |t abla u(x,t)|^2 frac{mathrm{d}mumathrm{d} t}{t}<infty,$$ if and only if, $u$ can be represented as the Poisson integral of the Schrodinger operator $mathscr{L}$ with trace in the BMO space associated with $mathscr{L}$.