public static bool Exists(IGeoProcessor gp, string modalname)
{
IGpEnumList pList = gp.ListTools("");
string name = pList.Next();

while (name != "")
{

if (modalname == name) return true;
name = pList.Next();

}
return false;
}