At first I wrote only one line:
# Include <windef. h>
The following error occurs during compilation:
1> C:/program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (5547): Error c2146: syntax error: Missing ";" (before the identifier "contextrecord") <br/> 1> C: /program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (5547): Error c4430: Missing type specifier-assumed to be Int. Note: C ++ does not support default int <br/> 1> C:/program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (5547): Error c4430: Missing type specifier-assumed to be Int. Note: C ++ does not support default int <br/> 1> C:/program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11265): Error c2065: "pcontext": Undeclared identifier <br/> 1> C:/program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11266): Error c2146: syntax error: Missing ")" (before the identifier "contextrecord") <br/> 1> C: /program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11266): Warning c4229: The note error is used: the modifier on the data is ignored. <br/> 1> C: /program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11266): Error c2182: "rtlcapturecontext": Invalid use of the "Void" type <br/> 1> C: /program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11266): Error c2491: "rtlcapturecontext": dllimport data definition not allowed <br/> 1> C: /program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (11266): Error c2059: syntax error: ")" <br/> 1> C:/program files/Microsoft sdks/Windows/v6.0a/include/winnt. H (12937): Error c3861: "_ readfsdword": unable to find the identifier <br/> 1> E:/personal_files/C ++ _ Project/testsdk/hikvisionsdk. H (214): Error c2061: syntax error: identifier "systemtime" <br/> 1> E:/personal_files/C ++ _ Project/testsdk/hikvisionsdk. H (395): Error c2061: syntax error: identifier "systemtime" <br/> 1> E:/personal_files/C ++ _ Project/testsdk/hikvisionsdk. H (397): Error c2061: syntax error: identifier "systemtime" <br/> 1> E:/personal_files/C ++ _ Project/testsdk/hikvisionsdk. H (398): Error c2061: syntax error: identifier "systemtime" <br/> 1> E:/personal_files/C ++ _ Project/testsdk/hikvisionsdk. H (409): Error c2061: syntax error: identifier "systemtime"
Then I searched for information on the Internet and found that I changed # include <windef. h> to # include <windows. h>. No error was reported during program compilation.
You can refer to the following URL:
Http://topic.csdn.net/u/20080406/10/2e6b8dc4-73f7-444f-ac89-39d63687a4e8.html