Login
Sting in C
186 просмотров
Перейти к просмотру всей ветки
in Antwort Simple 06.10.06 19:54
Лучше char *strncpy( char *strDest, const char *strSource, size_t count );
Еще лучше (для совместимости с юникод) _tcsncpy(TCHAR *strDest, const TCHAR *strSource, size_t count);
И наконец самое лучшее:
LPTSTR lstrcpyn(
LPTSTR lpString1, // destination buffer
LPCTSTR lpString2, // string
int iMaxLength // number of characters to copy
);
Еще лучше (для совместимости с юникод) _tcsncpy(TCHAR *strDest, const TCHAR *strSource, size_t count);
И наконец самое лучшее:
LPTSTR lstrcpyn(
LPTSTR lpString1, // destination buffer
LPCTSTR lpString2, // string
int iMaxLength // number of characters to copy
);
Я вам один умный вещь скажу - но только вы не обижайтесь...