From: aaron on 1 Jun 2010 09:14 Since I am new to vb.net 2008, I have the following question to ask: Since a solution (.sln file) can have several projects in it, can one project file work with another project file? In other words, can 'object a' in 'project file 1', work with 'object b' in 'project file 2' by using methods in ''object b' where 'properties values' are exposed to 'public' access? For example, can object 'manage finances' in 'project file 1' obtain the 'checking account' values from object 'customer' in 'project file 2'? If so, can you tell me and/or point me to a url that can explain how to accomplish this task?
From: Armin Zingler on 1 Jun 2010 10:10 Am 01.06.2010 15:14, schrieb aaron: > Since I am new to vb.net 2008, I have the following question to ask: > Since a solution (.sln file) can have several projects in it, can one > project file > work with another project file? In other words, can 'object a' in 'project > file 1', > work with 'object b' in 'project file 2' by using methods in ''object b' > where 'properties values' are exposed to 'public' access? For example, can > object 'manage finances' in 'project file 1' obtain the 'checking account' > values from object 'customer' in 'project file 2'? If so, can you tell me > and/or point me to a url that can explain how to accomplish this task? If one project is a "class library" project, you can reference it from any other project. In the "set reference" dialog, choose the class library project on the "projects" folder. Then you can access all available items from the class library. You may specify the full qualified name like Classlibrary1.ANamespace.ClassName or "Import" items like within the same project. Be aware that every project is made of layers. Every layer can only access lower layers. If you have multiple applications (.exe files) that you want to communicate with each other at run time, you must look for IPC (inter process communication) in the .Net Framework documentation. -- Armin
From: aaron on 1 Jun 2010 11:39 "Armin Zingler" wrote: How about if both projects are not a "class library", can one project in the same solution access another solution? If so, how would this be setup to occur? "Armin Zingler" wrote: > Am 01.06.2010 15:14, schrieb aaron: > > Since I am new to vb.net 2008, I have the following question to ask: > > Since a solution (.sln file) can have several projects in it, can one > > project file > > work with another project file? In other words, can 'object a' in 'project > > file 1', > > work with 'object b' in 'project file 2' by using methods in ''object b' > > where 'properties values' are exposed to 'public' access? For example, can > > object 'manage finances' in 'project file 1' obtain the 'checking account' > > values from object 'customer' in 'project file 2'? If so, can you tell me > > and/or point me to a url that can explain how to accomplish this task? > > If one project is a "class library" project, you can reference it from > any other project. In the "set reference" dialog, choose the class library > project on the "projects" folder. Then you can access all available > items from the class library. You may specify the full qualified name > like Classlibrary1.ANamespace.ClassName or "Import" items like within > the same project. > > Be aware that every project is made of layers. Every layer can only > access lower layers. > > If you have multiple applications (.exe files) that you want to communicate > with each other at run time, you must look for IPC (inter process communication) > in the .Net Framework documentation. > > -- > Armin > > > . >
From: Armin Zingler on 1 Jun 2010 13:05 Am 01.06.2010 17:39, schrieb aaron: > "Armin Zingler" wrote: > > How about if both projects are not a "class library", can one project in > the same solution access another solution? If so, how would this be setup to > occur? If you start an executable, a new process is created. DLLs are libraries that are loaded dynamically into the process space of a process. If you have multiple "Exe" projects (Winforms project, Console project) in the same solution, you can choose which of these projects shall be started whenever you start debugging. Every executable started is a separate process. Even if the same Dll (class library) is referenced by different projects and is consequently loaded into different process spaces, they don't share common data. Therefore you must use IPC as mentioned. In the very most cases there is only one Exe project in a solution. -- Armin
From: aaron on 1 Jun 2010 16:23
I basically have a vb.net 2008 solution that I need to make changes to. I am trying to determine how this solution (.sln file) is setup. There is no documentation. When I compile this application is debug mode, it needs lots of files. If I compile the .sln file in 'release' mode, the application compiles with a few warnings. Basically I am trying to determine how this .sln is setup beofre I make any changes to it. Why would buidling in release mode versus debug mode make a difference? Does it make sense to add a reference to a .dll file in release mode but not in debug mode? "Armin Zingler" wrote: > Am 01.06.2010 17:39, schrieb aaron: > > "Armin Zingler" wrote: > > > > How about if both projects are not a "class library", can one project in > > the same solution access another solution? If so, how would this be setup to > > occur? > > If you start an executable, a new process is created. DLLs are libraries that > are loaded dynamically into the process space of a process. > > If you have multiple "Exe" projects (Winforms project, Console project) in > the same solution, you can choose which of these projects shall be started > whenever you start debugging. Every executable started is a separate process. > Even if the same Dll (class library) is referenced by different projects and > is consequently loaded into different process spaces, they don't share common > data. Therefore you must use IPC as mentioned. > > In the very most cases there is only one Exe project in a solution. > > > -- > Armin > . > |