Ovulation

After I get my first peak how long do I have to have sex and get pregnant....?