shiffin
asked on
Is there any restriction on characters used in CMapWordToPtr key value?
What are the unacceptable characters in the key?
Thanks
Eugene
Thanks
Eugene
ASKER
I am sorry. It was CMapStringToPtr
Thanks
Eugene
Thanks
Eugene
Then you have the answer. Unique restricted character: ASCII 0
The same restrictions as for CStrings apply. What chracter/string is giving you trouble?
ASKER
I think I am doing a different mistake
Inside loop, I remove some keys. I think this is the problem. Is it?
Eugene
Inside loop, I remove some keys. I think this is the problem. Is it?
Eugene
pCurVal= myMap.PGetFirstAssoc( );
while (pCurVal != NULL)
{
pCurVal= myMap.PGetNextAssoc(pCurVal);
if(OnSomeCondition){
delete myMap.pointer
myMap.RemoveKey("xxx")
}
}
if(myMap.IsEmpty())myMap.RemoveAll()
So far, that looks ok. What error are you getting and what is the original code?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Word means a 16-bit integer, not a string at all
Maybe you need CMapStringToPtr, unique forbidden character is null (ascii 0)