I have common classes that I would like to share amongst a few stand
alone projects. They are independent of each other and not related in
any way. For the life of me, I cannot figure out how to share a
single source code file amongst multiple projects. When I attempt to
add an existing item to a project, Visual Studio makes a copy of the
file. I do not want ten copies of the same source code that I later
have to maintain.
I tried editing the file name and adding ..\Common\whate ver.vb, but
this is not permitted. It seems like such a simple thing that I
should not be struggling with.
Any help would be appreciated.
Thanks. 5 1273 ja***@onepost.n et wrote in news:at******** *************** *********@4ax.c om:
I have common classes that I would like to share amongst a few stand
alone projects. They are independent of each other and not related in
any way. For the life of me, I cannot figure out how to share a
single source code file amongst multiple projects.
Create a library (DLL).
<ja***@onepost. netschrieb:
[...] I cannot figure out how to share a
single source code file amongst multiple projects. When I attempt to
add an existing item to a project, Visual Studio makes a copy of the
file. I do not want ten copies of the same source code that I later
have to maintain.
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://dotnet.mvps.org/dotnet/faqs/>
On Sun, 15 Jul 2007 19:39:31 +0200, "Herfried K. Wagner [MVP]"
<hi************ ***@gmx.atwrote :
>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.
Interesting -- I do not have these options after clicking Add Existing
Item.
Ah -- I just found it. There's a drop down arrow to the right of the
Add button. I have to select "Add As Link."
Thanks!
On Sun, 15 Jul 2007 17:37:27 GMT, Spam Catcher
<sp**********@r ogers.comwrote:
>Create a library (DLL).
Yeah -- this would have been my last resort. I have the source shared
now though. ja***@onepost.n et wrote in news:vm******** *************** *********@4ax.c om:
On Sun, 15 Jul 2007 17:37:27 GMT, Spam Catcher
<sp**********@r ogers.comwrote:
>>Create a library (DLL).
Yeah -- this would have been my last resort. I have the source shared
now though.
It's probably the best way too :-) This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
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?
|
by: Dan |
last post by:
I'd like to have a set of more-or-less common code which I want to use for
both desktop and smart device projects. I have two questions:
1. How can I set up conditional compile directives for those parts of the
code which are different on desktop and smart device projects
2. How can I actually share the same .cs source code files between the two
projects. If I try to open a smart device project and add the files which
are in the...
|
by: geoffblanduk_nospam |
last post by:
Is it valid to share namespaces across projects in C#?
For example, I have a project that contains the code for a core
assembly, this builds a DLL. I then have a second project in the same
solution that contains test cases for the assembly in the same
namespace, this references the first project's DLL and builds a further
DLL for testing. All code has the same namespace. The code in the tests
needs access to internal methods etc of the...
|
by: John Lafrowda |
last post by:
Dear all,
here is a simple problem that I cannot overcome:
I'm trying to write a client/server application in Visual Basic .net. The
server is an executable (.exe) project, the clients are class library (.dll)
projects. The server loads the clients from their DLL-files at runtime using
reflection tools, such as:
ClientAssembly =
System.Reflection.Assembly.LoadFrom(Client_To_Load_File_Name)
|
by: Carlo \(MCP only\) |
last post by:
Hi to all
I'm askyng you a suggestion about the best way to share the same source code
between VS2003 and VS2005.
The project I'm developing is a controls and components library, and the
Solution.sln includes a standard WindowsForms application for testing
pourposes.
What I need is an efficient and reliable way to edit and test the DLL
assembly in both environments, since the library will be distributed for
Framework 1.1 and 2.0.
| |
by: Chris Fink |
last post by:
What is the recommendation for sharing master pages across IIS Servers? In
our corporation, we have many webservers in different environments (intranet,
extranet, etc). I've done some searching, and it appears as though the
solutions are focused only around one IIS instance, by installing the
controls (master pages) in the GAC. This solution would require me to
install the controls in more than 1 dozen servers each time.... I would think...
|
by: Matt Owens |
last post by:
Hi,
Im setting up a new project in which I'd like to share code across
numerous other projects, specifically a control library and an array
of common objects. Im not really sure how best to go about this, i've
done this two ways in the past and both have proved a little
problematic.
1) Create a new solution in a common area with a common name for all
projects to share. This is fine, although there's the overhead of
|
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...
|
by: =?Utf-8?B?QmV0aA==?= |
last post by:
Hello.
I'm trying to find another way to share an instance of an object with other
classes.
I started by passing the instance to the other class's constructor, like this:
Friend Class clsData
Private m_objSQLClient As clsSQLClient
Private m_objUsers As clsUsers
|
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,...
|
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...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
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...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
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...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
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
| |
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...
| |