Hey,
I know there is a windows board, but I think the problem is in the non-visual part.
I want to extract user input from edit boxes into an array. The code I have only works if all the boxes are filled. I want it to keep going if the edit box is empty and just not put that value into the vector. Here's what I got:
Code:
structLink templink;
CEdit* pGetEdit[512];
for(i=0; i<FAD.nExpected; i++)
{
pGetEdit[i] = (CEdit*) GetDlgItem(i+100);
int len = pGetEdit[i]->LineLength();
if(len > 0)
{
pGetEdit[i]->GetLine(1,templink.ParamName.GetBuffer(len), len);
templink.Index = i;
vars.vectParmSelected.push_back(templink);
}
}
I get a run time error that memory could not be read. My check for emprty strings maybe wrong or something else.
thanks a lot.