For Programmers: Free Programming Magazines  


Home > Archive > VC STL > January 2006 > Problems with CMap in VC++ 7









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Problems with CMap in VC++ 7
Jorge Varona

2006-01-24, 7:07 pm

Greetings,

I'm having a problem with an app that has just recently been converted from
VC++ 6 to VC++ 7. For whatever reason my CMAP lookups are inconsistent. That
is, they always return true, however, values are missing. I'm wondering if
there are any known issues with CMap in .Net that may be affecting this.
Here's the code being called:

bool CRateInfo::LookupRateCode(const long nRateCode,

CRateCode** ppRateCode,

CString& strErrorDescription /*= (TCHAR)0*/) const

{

bool bRetVal = false;

*ppRateCode = NULL;

if (m_RateCodeSet.Lookup(nRateCode, *ppRateCode))

{

if((*ppRateCode)->m_strRateCode.IsEmpty())

int jsds = 100;

bRetVal = true;

}

else

if (strErrorDescription != (TCHAR)0 &&

strErrorDescription.IsEmpty() )

strErrorDescription.Format("LookupRateCode: Cannot Locate RateCode
(%ld)",nRateCode);

return bRetVal;



Thanks,

Jorge


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com