If you are writing to someone who has a doctorate or medical degree, use the abbreviated form: "Dr." However, for other titles, such as professor, judge, rabbi, etc., write out the full title and capitalize it. For example, your salutation in a letter to a judge would be, "Dear Judge Barnard." Or, if your correspondence was with a rabbi, you might write, "Dear Rabbi Williams."
In most cases, the business letter will be the first impression that you make on someone. Though business writing has become less formal over time, you should still take great care that your letter’s content is clear and that you have proofread it carefully.