CString strOcxPath = this->m_pszHelpFilePath;
CString strOcxName = this->m_pszExeName;
strOcxName += ".HLP";
int nTmp = strOcxName.GetLength();
nTmp = strOcxPath.GetLength() - nTmp;
m_StrRealOcxPath = strOcxPath.Left(nTmp);
m_StrOcxPath = m_StrRealOcxPath + L"InOutBGSetInfo.ini";
CString strTemp1, strTemp2;
GetLongPathName(m_StrRealOcxPath, strTemp1.GetBuffer(MAX_PATH), MAX_PATH);
GetLongPathName(m_StrOcxPath, strTemp2.GetBuffer(MAX_PATH), MAX_PATH);
strTemp1.ReleaseBuffer();
strTemp2.ReleaseBuffer();
m_StrRealOcxPath = strTemp1;
m_StrOcxPath = strTemp2;
CString strOcxName = this->m_pszExeName;
strOcxName += ".HLP";
int nTmp = strOcxName.GetLength();
nTmp = strOcxPath.GetLength() - nTmp;
m_StrRealOcxPath = strOcxPath.Left(nTmp);
m_StrOcxPath = m_StrRealOcxPath + L"InOutBGSetInfo.ini";
CString strTemp1, strTemp2;
GetLongPathName(m_StrRealOcxPath, strTemp1.GetBuffer(MAX_PATH), MAX_PATH);
GetLongPathName(m_StrOcxPath, strTemp2.GetBuffer(MAX_PATH), MAX_PATH);
strTemp1.ReleaseBuffer();
strTemp2.ReleaseBuffer();
m_StrRealOcxPath = strTemp1;
m_StrOcxPath = strTemp2;
本文介绍了一种在C++中构建完整文件路径的方法,并展示了如何处理特定类型的文件,包括获取长路径名称及拼接路径。
575

被折叠的 条评论
为什么被折叠?



