|
|
1鱼币
以下代码编译时没错,执行时出错,错误如下,求解?
--------------------Configuration: 文本颜色 - Win32 Debug--------------------
Linking...
0.obj : error LNK2001: unresolved external symbol _textcolor
Debug/文本颜色.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
文本颜色.exe - 2 error(s), 0 warning(s)
#include <conio.h>
void main(void)
{
int color;
for (color = 1; color < 16; color++)
{
textcolor(color);/*设置文本颜色*/
cprintf("This is color %d\r\n", color);
}
textcolor(128 + 15);
cprintf("This is blinking\r\n");
}
|
最佳答案
查看完整内容
你是用VC编译的?
你百度查一下textcolor上百度百科,可以发现这个东西,表示VC这个IDE的头文件中没有该函数,你换个有该函数的头文件试试
|