Ahmad Al Halabi wrote:
I want to copy function in another project
You need to use
access modifier public
for function and its declaring type, to make it accessible from other assemblies. And you need to reference this assembly by the one where you want to use it. That's it.
Of course, you don't want to copy a function. I think you just used wrong words. But also, you need to learn terminology and the basics of programming. During runtime, there are no projects, there are only assemblies and modules. When you have, say, two projects in on solution and add one project to another as a reference (always a good idea), this is merely a good way to make one assembly referenced another one automatically, even if you rename, move the project, sign it (it changes its
strong name) and so on. You need to learn assemblies, types vs instances, static vs instance members, and a lot more.
—SA