You should be putting a breakpoint in your application's entry and stepping until you encounter the crash (or just spam printf's everywhere), it's probably not DirectX that's failing here but StdAfx.h, since you said previous examples work.
I also had to put in #include <StdAfx.h> on the other examples (the white screen and the blue screen), and both of those examples worked. So I kind of think that the StdAfx.h is just needed for Visual Studio itself to easier rebuild the headers etc. And that part works fine.
The problems seems to me to be either the load of the shaders.hlsl file doesn't work as intended, or there is something else that does work with the shader function invoked. Very strange, though?
I might add to say that all examples before the triangle is to be drawn works fine. So the first example of the "white screen" works. Also the "blue screen" example works. But not the example where it draws the triangle.
Guys, how did you make the examples work from that tutorial site? All that happens when I build that project is that the build goes OK - but when I run the file the application itself crashes. Regardless if I use reference or hardware mode on the driver settings...
Any ideas why it crashes? The white window with the DirectX application do turn up on the screen - but it crashes direct after.