It is possible using the C ++ / CLI . This is a managed version of C ++ that is used with .Net.
I will not go into too many details because you probably will not want to use it. In fact it is only usually used as a glue between native C # and C ++ applications. That is, you are going to do the main part of the C # application, and will use that from C ++ / CLI to give access to C # to functions written in native C ++.
Of course you can use the code in C ++ in C ++ / CLI. It's not pure C ++ but it's pretty much the same in almost everything. But it is likely to require some adaptations.
Avoid doing this but there is a possibility. If it is going to be passed to C #, think about whether there is any reason to leave a part in C ++. Usually do not have to. You will only create complications without having any benefit.