If an investor is short a stock on record date, he is not entitled to the dividend. In fact, he is responsible for paying the dividend to the lender of the stock. Investors short a stock if they expect it to decline in value. Shorting a stock is essentially selling it and then buying it back at a future price. If the price falls, there is a profit. If the price rises, there is a loss. The stock needs to be borrowed from a shareholder to sell it without owning it. This process is usually handled by a brokerage firm. There is generally a borrowing fee for the stock depending on its availability and liquidity. Additionally, the borrower of the stock is responsible for paying any dividends.
Shorting stocks is considered risky and appropriate only for sophisticated traders due to the general upward trend of stocks, borrowing costs and the skewed risk-reward nature of shorting. Over time, stocks appreciate as inflation erodes away the value of currencies. Companies, through their business operations, protect against inflation as they are able to pass on rising costs to customers. This is one reason for the general upward trajectory of stock indexes over time.
Borrowing costs can be significant depending on the stock, typically between 2% and 10% annually. Of course, there is the additional cost of paying out dividends. This is a significant drag on returns and compounds the difficulty of the task. Finally, basic math works against short selling as well. A stock can go up by multiples if there is a takeout offer or the company comes out with some innovative product.