Hmmm....
Well, instead of using DirectX 8.1, you should use DirectX 9.
Did you replace the ddraw.h in DirectDraw 4 with the one for DirectDraw 9?
I looked at my own DirectX game, and found this:
IID_IDirectDraw7
Seeing as how it's case sensitive(or at least that's how my compiler works), you should try uncapitalizing the middle of the words.