473,624 Members | 2,453 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Sharing files across projects

I have a VB.NET class library project and two other VB.NET projects that
depend on that class library, ie:

Class library
--Project 1
--Project 2

Currently, as you'd expect, when I compile this, each of Project 1 and 2 end
up with an exe and a dll. However, I don't want the project to be distributed
with a dll, so is it possible to add the files to each of the Projects
directly (so that they are sharing the files in the class library -- not such
that each gets a separate copy) rather than using the class library as a
dependency. In this way, if I update the class library, both project file
sets will also be updated. And when I compile each project, the resulting
output will only be an exe?
Nov 21 '05 #1
2 1292
"Andrew E Chapman" <An************ @discussions.mi crosoft.com> schrieb:
Currently, as you'd expect, when I compile this, each of Project 1 and 2
end
up with an exe and a dll. However, I don't want the project to be
distributed
with a dll, so is it possible to add the files to each of the Projects
directly (so that they are sharing the files in the class library -- not
such
that each gets a separate copy) rather than using the class library as a
dependency. In this way, if I update the class library, both project file
sets will also be updated. And when I compile each project, the resulting
output will only be an exe?


Click "Add Existing Item...", select the file, and then change the
dropdown button to reference the file only and keep it in its original
location.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #2
Thanks, that sort of worked. The program would compile and run, but there is
now a problem with serialization. Project1 and Project2 pass serialized
binary data to one another, but when Project2 now attempts to deserialize
data from Project1 it throws a "Cannot find assembly Project1" error, which
was not occuring before when the class library was compiling into a dll.

From my reading I understand this is something to do with versioning, but
I've no idea how to fix it.
Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1944
by: Simon Neve | last post by:
Hello, This question is related to sharing .Net projects across solutions and is reposted from the SourceSafe group. We have several different solutions and want to share common assemblies across them. Is it best to share the project and its files to each solution (each solution has it's own shared project), or have each solution point to the same file location of the project?
0
1204
by: Daniel | last post by:
Hi! I have several projects (approx 50) that includes basically the same files such as <atlcom.h> and <comdef.h>. The projects are set up to use a precompiled header wich includes these header files (<atlcom.h> and <comdef.h>) and that works fine. But since these files are used in all the projects and every project have a separate precompiled header these files get compiled a lot of times. Is it possible to do anything about this? Is it...
1
329
by: Simon Neve | last post by:
Hello, This question is related to sharing .Net projects across solutions and is reposted from the SourceSafe group. We have several different solutions and want to share common assemblies across them. Is it best to share the project and its files to each solution (each solution has it's own shared project), or have each solution point to the same file location of the project?
2
2275
by: David | last post by:
How do I share code across files in C#, without including a reference to a class library. Here's what I want to do. I have a device I want to talk to. It's a machine in a factory. It can talk on a serial port, or over ethernet. Either way it's talking, it sends the same data. So, I encapsulate the data structure in a class, and I stick the class in a .cs file. Now, I want to create three projects, and they all will deal with the...
2
1967
by: Jeff Dege | last post by:
I'm working with a group that's been doing C++ coding for quite a long time, now, and in that environment we've pretty much worked out development practices that serve us well. We've been doing more and more, over the last few years, in C# and ASP.NET. Some web apps, some background services. In our C++ code base, we have a fair number of statically-linked libraries that contain code we share between projects. At this point, in our...
0
8175
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8680
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8482
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6111
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5565
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4177
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2610
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1791
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1487
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.