A loan is a fixed amount of money with a fixed repayment period. It's fairly straightforward. You know what you'll borrow, for how long and how much you'll pay. Easy, right?
A line of credit is a revolving loan that lets you borrow up to a certain approved limit. You only pay interest on the amount that you have used and the interest rates are generally lower than what you'll pay with a credit card. You may want to set up a line of credit so you are prepared for emergencies, or you may want to pay off a higher interest credit card. A line of credit can also offer you protection against overdrawn accounts.
Making payments on time is the most important action you can take to improve and maintain a good credit score.