use \spadfunFromX{foo} instead of \spadfunFrom{foo!}