I use the measure and subtraction method. Most actions are round so it works fairly well, I guess you could also measure from the barrel right in front of the recoil lug.
Measure from top of scope tube to bottom of action (or barrel) = A
Measure scope tube diameter and divide in half = B
Measure action or barrel and divide in half = C
Formula is A minus B = X, X minus C = center of bore to center of scope, fairly accurately too.
You must take all measurements on the same place horizontally, i.e. don't measure the action and scope tube for A, the scope's objective bell for B, and the end of the barrel for C.
Most of my scope heights are about 1.7 - 2" using this method.
Ha Ha, guess someone posted same method while I was typing mine, lol.