Correct me if I forget something up, I haven't had a math class in a bit
tan(theta) will yield the ratio of opposite to adjacent. You have adjacent and want opposite. In order to find the opposite, x being your horizontal distance, your formula will just be x * tan(theta). This will be adjacent * opposite / adjacent, leaving you with the opposite side as your vertical component.
Does that make sense?
I wouldn't normally give people this, but it's an odd form of question and I get why you're confused.