# DirectX 12 using Visual studio 2015 on Windows 7 SP1

I'm trying to work with a directx 12 sample using windows 10 sdk, visual studio 2015, on windows 7 SP1. I get the following error

The procedure entry point CreateFile2 could not be located in the dynamic link library Kernel32.dll

• DirectX 12 requires Windows 10. – SurvivalMachine Oct 23 '16 at 15:05
• CreateFile2 - "Minimum supported client : Windows 8" - this is aside from the Windows 10 requirement to use D3D12. – Maximus Minimus Oct 23 '16 at 17:22

• That's correct. You can use the Windows 10 SDK to build a desktop application on Windows 7 Service Pack 1, but you must use APIs that are supported by Windows 7 Service Pack 1 if you want to run it on that system. Typically this is handled by setting _WINNT_WIN32 to 0x0601 for Windows 7 or 0x0A00 for Windows 10. Unsupported COM-based APIs will of course fail to create. See Using the Windows Headers. – Chuck Walbourn Oct 24 '16 at 16:37
• As noted, DirectX 12 is only supported on Windows 10. CreateFile2 is supported on Windows 8.0, Windows 8.1, and Windows 10. Again, it is possible to write a desktop application that uses DirectX 12 on Windows 10 and falls back to DirectX 11 for Windows 7 SP1, but this requires careful planning. For simplicity, most of our DX12 developer education material is assuming you are running Windows 10 and makes other assumptions such as CreateFile2 being supported--as to why CreateFile2 exists in the first place, this is to support the AppContainer security context used by Windows Store. – Chuck Walbourn Oct 24 '16 at 16:39