About 24 passengers were injured in the early Saturday morning incident in the state of Parana.
Police cited passengers who said the driver lost control of the bus when the shots were fired.
Four women and six men, including the driver, were killed when the bus hit the tree.
The bus was taking the passengers to neighboring Paraguay to shop at the duty free stores in the city of Ciudad del Este.
The would-be robbers fled.