You need to be canny, careful, and assiduous in your search for an agent or a publisher, but—this bears repeating—the most important thing you can do for yourself is read the market.
“Please be careful, Hagrid.” said Mr. Weasley, who was standing beside them, holding his broomstick. “I'm still not sure that was advisable and it's certainly only to be used in emergencies.”