咋在c语言2010中编译,如何在visual c express 2010中编译c代码

我试图在VS C express 2010中编译c代码,但我得到以下错误跟踪:

1>------ Build started: Project: test4, Configuration: Release Win32 ------

1>cl : Command line error D8045: cannot compile C file 'test4.c' with the /clr option

========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

当我尝试使用cpp扩展编译时,我得到此错误跟踪:

1>------ Build started: Project: test4, Configuration: Release Win32 ------

1> test4.cpp

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(86): error C2664: 'CreateFileW' : cannot convert parameter 1 from 'const char [13]' to 'LPCWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(98): error C2664: 'CreateFileW' : cannot convert parameter 1 from 'const char [13]' to 'LPCWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(138): error C2664: 'OpenServiceW' : cannot convert parameter 2 from 'const char [9]' to 'LPCWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(196): error C2664: 'GetSystemDirectoryW' : cannot convert parameter 1 from 'CHAR [80]' to 'LPWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(203): error C2664: 'lstrcatW' : cannot convert parameter 1 from 'CHAR [80]' to 'LPWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(208): error C2664: 'CopyFile' : cannot convert parameter 1 from 'const char [13]' to 'LPCTSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>c:\documents and settings\rkelly1\desktop\io\test4\test4\pt_ioctl.c(236): error C2664: 'CreateServiceW' : cannot convert parameter 2 from 'const char [9]' to 'LPCWSTR'

1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast

1>test4.cpp(27): error C3861: 'kbhit': identifier not found

========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值