Using Multibyte character set in building the example from MSDN we get the "initializer is not a constant" error for the last line. VS10 SP1, no CLR.
#define arraysize 30
TCHAR pszDest[arraysize];
size_t cbDest = arraysize * sizeof(TCHAR);
LPCTSTR pszFormat = TEXT("%s %d + %d = %d.");
TCHAR* pszTxt = TEXT("The answer is");
HRESULT hr = StringCbPrintf(pszDest, cbDest, pszFormat, pszTxt, 1, 2, 3);
// The resultant string at pszDest is "The answer is 1 + 2 = 3."
Other CLR options fail. Anyway of removing the error?