The below article explains how to setup a your InfoPath environment for local debugging...
http://support.microsoft.com/kb/555963