Should be a straight swap. Besides different porting, these cylinders should be identical. In Eric's book, he recommends the '99 cylinder & porting for many riders.
The '99 has more mild porting so look for increased bottom end power and a less abrupt hit. The stock '99 pipe is good and works well with the '99 cylinder, so you if your friend has his pipe, try to get it too. You may need to alter your jetting from what you were running on your '97.