I am looking for a C++ Builder equivelent to this MFC Code. The code I am concerned about is the CByteArray type, CString.Mid method.
Thanks for any help.
CString fileName;//Create file path
CString strTemp;//Temp string
CString strLow;//byte low
CString strHigh;//byte high
CString strTr;//Input string
CByteArray byteTr;//Input byte
long rtNext = 0;//See part of 2byte and start position
byteTr.SetSize(m_Cochkscan1.GetImageDataSize() / 2);
for(long i = 0;i < m_Cochkscan1.GetImageDataSize() /2;i++){
strHigh = strTemp.Mid(rtNext,1);
strLow = strTemp.Mid(rtNext+1,1);
rtNext = rtNext + 2;
byteTr.SetAt(i,(BYTE)(strChange(strHigh) * 16 + strChange(strLow)));
}
ImCreateFile(fileName);
Thanks for any help.
CString fileName;//Create file path
CString strTemp;//Temp string
CString strLow;//byte low
CString strHigh;//byte high
CString strTr;//Input string
CByteArray byteTr;//Input byte
long rtNext = 0;//See part of 2byte and start position
byteTr.SetSize(m_Cochkscan1.GetImageDataSize() / 2);
for(long i = 0;i < m_Cochkscan1.GetImageDataSize() /2;i++){
strHigh = strTemp.Mid(rtNext,1);
strLow = strTemp.Mid(rtNext+1,1);
rtNext = rtNext + 2;
byteTr.SetAt(i,(BYTE)(strChange(strHigh) * 16 + strChange(strLow)));
}
ImCreateFile(fileName);