Investors & landlords

Can I buy another rental property with the sale of current property and sell it immediately after a year or so?