Create convertbasefunction