We can actually express [itex]|\psi\rangle[/itex] as a sum (integral) over all the position states:
[itex]|\psi\rangle = \int dx |x\rangle\langle x|\psi\rangle = \int dx |x\rangle \psi(x)[/itex]
[itex]\psi(x) = \langle x|\psi\rangle[/itex] is the component of [itex]|\psi\rangle[/itex] that overlaps with the position basis vector [itex]|x\rangle[/itex].
It's an inner product, like with ordinary vectors. If you want to find the y-component of a vector [itex]\vec{v}[/itex], you take its inner product with the basis vector in the y-direction [itex]v_{y} = \vec{v}\cdot \hat{y}[/itex].
We can also express these components [itex]\langle x|\psi\rangle[/itex] in other bases too. If we have some other (discrete) basis of states [itex]|k\rangle[/itex], we can express [itex]\langle x|\psi\rangle[/itex] as:
[itex]\langle x|\psi\rangle = \sum_{k}\langle x|k\rangle\langle k|\psi\rangle = \sum_{k} \psi_{k}(x) C_{k}[/itex]
where
[itex]C_{k} = \langle k|\psi\rangle[/itex]
On the other hand, we can also represent [itex]C_{k}[/itex] in terms of the position basis states [itex]|x\rangle[/itex], so that
[itex]C_{k} = \int dx\; \langle k|x\rangle\langle x|\psi\rangle = \int dx\; \psi_{k}^{*}(x)\psi(x)[/itex]
The probability to measure [itex]\psi_{m}(x)[/itex] is better thought of as just the probability of measuring [itex]k=m[/itex]. This probability is just [itex]|\langle m|\psi\rangle|^{2} = |C_{m}|^{2}[/itex].