VS2005及2008不能用 strtok?

来源:百度知道 编辑:UC知道 时间:2024/05/14 14:09:45
VS2005及2008好象是不能用 strtok
那各位达人们都用什么函数去拆分字符串呢?
帮帮我,
先谢了.
程序报错: warning C4996: 'strtok' was declared deprecated
e:\microsoft visual studio 8\vc\include\string.h(164) : see declaration of 'strtok'
Message: 'This function or variable may be unsafe. Consider using strtok_s instead. To disable deprecation, use _CRT_SECURE_NO_DEPRECATE. See online help for details.'

怎么会呢,我在vs2008控制台下试了能使用的。如果你是在windows程序中,请确认的默认编码是ascii码。如果是unicode码,请用wcstok函数替换该函数。其他字符串处理函数都需要改变的