If they're both 135 * 10mm, mtb dropouts yes. If it's an Eastern or something else with a 14mm rear axle dropout, no, but this is the exception, not the rule.
Consider, if you're using a horizontal dropout, whether the hub is appropriate for that dropout (not just if it will fit) - ie is it a bolt-up or nutted axle versus a standard QR type - which will often slip in a horizontal dropout.
- Joel