STARTUPINFO si; PROCESS_INFORMATION pi; memset(&si, 0, sizeof(si)); memset(&pi, 0, sizeof(pi)); si.cb = sizeof(si); LPCWSTR procName =(LPCWSTR)\"D:\\\\test
You use the L prefix to make a wide character string:
L
L"D:\\test dir 1\\Calc.exe";
Casting a string literal to a different character width does not make a string wider.