I have a C# solution, let's say MySolution
and inside this I have 2 projects, let's say ProjectA
and ProjectB
. ProjectA
is used as a reference for ProjectB
.
How can I obtain the version of ProjectB
inside the classes from ProjectA
?
I can obtain the version of ProjectB
inside the code of ProjectB
by using the following syntax :
System.Reflection.Assembly.GetExecutingAssembly().GetName().Version