There shouldnt be any problem working while defragging, although obviously your work will go slower since the disk is thrashing. The files you have open will be locked, and wont be defragmented, but that shouldnt be a big deal unless you have dozens of apps open, and even then it shouldnt effect much in the scheme of things.
XP isnt like 9x, where every little disk access restarted the defragmenter. XP is smarter than that now.
Usually the only thing that will trip up the defragmenter will be disk errors, which it *should* pick up on, and will tell you to do a chkdsk (the XP version of scandisk).
Which defragmenter are you using? The one that comes with XP, or another one?