The IB demo workbook is a good place to get the relevent code.
However, if you're using excel 97 then two of the functions within the code aren't supported, causing the macros to fail.
They're not critical and if you remove them from the code it works fine.