One thing worth mentioning...
What compiler are you using? It can be a real pain to get the DirectX SDK running with GCC or other similar compilers. You should use Visual Studio to compile DX...