X-Git-Url: http://Server1/repobrowser/?a=blobdiff_plain;f=source%2Fcontacteditor%2FfrmContactEditorOrganisations.cpp;h=876371035ba37e30b8d33043f2039c4ee2f3b816;hb=296baaf67d5aef9ed8e57f9de85a3d16ea86d767;hp=b6c2e19fcdb1cb459040e246b97f802a5560fc0a;hpb=da64d37d0a13895554e4ad945c46dd0af6d1c0e6;p=xestiaab%2F.git diff --git a/source/contacteditor/frmContactEditorOrganisations.cpp b/source/contacteditor/frmContactEditorOrganisations.cpp index b6c2e19..8763710 100644 --- a/source/contacteditor/frmContactEditorOrganisations.cpp +++ b/source/contacteditor/frmContactEditorOrganisations.cpp @@ -239,7 +239,8 @@ void frmContactEditorOrganisations::SetEditorMode(bool EditMode, SectionType Sec striter = OrganisationListSortAsPtr->find(OrganisationListIndex); - if (striter->first == OrganisationListIndex){ + if (striter->first == OrganisationListIndex && + striter != OrganisationListSortAsPtr->end()){ strValue = striter->second; @@ -251,7 +252,8 @@ void frmContactEditorOrganisations::SetEditorMode(bool EditMode, SectionType Sec intiter = OrganisationListPrefPtr->find(OrganisationListIndex); - if (intiter->first == OrganisationListIndex && intiter->second > 0){ + if (intiter->first == OrganisationListIndex && intiter->second > 0 && + intiter != OrganisationListPrefPtr->end()){ sliPriority->SetValue(intiter->second); sliPriority->Enable();