You could do this easily with rules on the checkbox or with code in the OnAfterChange event.
1. To add rules double-click the checkbox, and then click the Rules button.
2. Click Add, set the condition so that the rule fires when checkbox is equal to TRUE, click OK.
3. Click Add Action.
4. Choose change a field's value - use the formula boxes to select the appropriate fields to copy from.
5. Click OK until you're back to the canvas.
The same could be done to erase the values when the checkbox is unclicked - just use set field's value to ""
Matt Faus / Microsoft InfoPath MVPQdabra® Software / Streamline data gathering to turn process into knowledge