Yes, trapping can be effective in controlling rat and mice infestations. Trapping is most effective when the problem is localized, such as in a home or when the quantity of mice/rats is low.
The key to effective trapping is to use enough traps (most people use too few), to properly place them, and to properly maintain them. Placing traps strategically where rodents have been noticed is very effective and inexpensive. Set the traps inside containers to prevent non-target captures. Bait stations are typically designed to allow snap traps to be placed inside.
The links below have some great tips for setting traps and preventing rodent infestations.
Find more information about pests in eXtensions Pest Management In and Around Structures Resource Area.