Пример #1
0
//DeleteProfile
bool Profiles::DeleteProfile (wstring sName)
{
    Err fErr (m_Err, L"DeleteProfile");

    Config *pProfile;
    if (!GetByName (sName, &pProfile))
    {
        return false;
    }
    if (remove (ConStr<char> (m_sDirectory +
                              pProfile->GetFileName ()).c_str ()) != 0)
    {
        return fErr.Set (L"Could not remove the given profile file");
    }

    return Reload ();
}//DeleteProfile