Sue in Ajax has seen enough home improvement TV shows to completely confuse her. When changing the siding and adding ridged foam insulation, should the house wrap go on first or last? She has seen it done both ways on TV.
The answer is Yes! That's right, both ways work fine.
The job of the house wrap is to block air movement through the wall, while not creating a vapour barrier. So the air barrier can be anywhere at all in the wall. It could even be behind the drywall if you want, but that would be very difficult to deal with the area behind partition walls and between floor/ceilings. Wrapped around the outside of the house, it covers everything. Sue is right that if you put it on first, you will get more nail holes in it. If you put it on last, it is more subject to damage and wind pressure. Many builders put it on over the insulation and hold it in place with 1x3 strapping, that then holds the new siding.
One interesting note: If you use the Canadian product from Dow called CladMate, it is classified as an air barrier itself. This particular foam is not a vapour barrier, the joints seal against each other and all you have to do is to tape shut any cut openings, like corners and windows and doors. Then you can leave the house wrap out all together.