Sudesh
2008-01-29 13:22:47 UTC
Hello
Whats happening with the following code?
I have a class FOO.
FOO *foo;
int Index_Count = 3000;
try
{
foo = new FOO[Index_Count];
}
catch(Exception & E)
{
MessageDlg("Error in Program: " + E.Message, mtError, TMsgDlgButtons()
<< mbOK, 0);
}
There is no exception, means memory allocation is successful. correct?
Now when I try to set value for a member at an index 400, foo[400].member1,
I get an error.
In debug mode foo[400].memb1 shows "????"
Whats going wrong?
Thanks,
Sudesh
Whats happening with the following code?
I have a class FOO.
FOO *foo;
int Index_Count = 3000;
try
{
foo = new FOO[Index_Count];
}
catch(Exception & E)
{
MessageDlg("Error in Program: " + E.Message, mtError, TMsgDlgButtons()
<< mbOK, 0);
}
There is no exception, means memory allocation is successful. correct?
Now when I try to set value for a member at an index 400, foo[400].member1,
I get an error.
In debug mode foo[400].memb1 shows "????"
Whats going wrong?
Thanks,
Sudesh