You can take an antibiotic for a stye if you want too as it will help fight off the infection causing the Stye.
However most times a Stye will go away within a week or two on it's own without medical treatment.
You can put a warm compress on the Stye to help get rid of it or even a warm tea bag applied to the stye can help get rid of the stye within 5 to 7 days.
If your stye hasn't gone away within two weeks then you should see a doctor for antibiotic ointment that they can prescribe that's much stronger than your over the counter antibiotic Stye ointments.