Checks if name is used in EditDialog