MajP,
For parameters, look at table-valued functions.
They can use your recursive CTEs.
They look like tables, but AFAIK you can't link them ... only as ADO entities, but can be used in SQL Server queries.
Sorry, *typing*on phone S L O W L Y.
Wayne
P.S. experiment in SSMS, SQL servers...