This expression derives from an old English sport, bullbaiting dogs try to pull a bull by his nose to the ground. Gamblers would place a bet "on the bull's eye" if he wished to make a bet. Crowns, an English coin, were used to bet so frequently "on the bull's eye that the coin itself came to be called a bull's-eye. Later, the term was applied to the black center of a target. The idiom right on the money is also derived from the ancient interchangeable use of a coin, bull's-eye and the center of a target. A sentence in this case would be: " You were right on the money with your speech."
The ballpark is probably derived from a baseball park.