//read file CFile* pFile = new CFile(filePathAndName, CFile::modeRead); ULONGLONG dwLength = pFile->GetLength();//I64u char* buffer = new char[(int)dwLength + 1];//add one extra to make space for null terminator buffer[dwLength] = 0; //This will make the last character a null terminator UINT nActual = pFile->Read(buffer, static_cast<UINT>(dwLength));//sizeof(szBuffer)); //convert char* buffer to LPCTSTR CString strLPCTSTR (buffer); m_displayData = strLPCTSTR; SetWindowText(m_displayData); int windowTextLength = GetWindowTextLength();
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)