473,804 Members | 3,196 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Using functions between projects

In one VB.Net 2003 solution, I have three projects (one in the installer
project and not relevant here). However, the other two are the ones where I
want to share some commone fucntions. One is a Windows Forms based app and
the other is a Windows Service. Is this possible?

TIA,
--
Anil Gupte
www.keeninc.net
www.icinema.com
Jan 1 '08
10 1404
Thanx!

--
Anil Gupte
www.keeninc.net
www.icinema.com

"Mr. Arnold" <MR. Ar****@Arnold.c omwrote in message
news:OK******** ******@TK2MSFTN GP02.phx.gbl...
>
"Anil Gupte" <an*******@icin ema.comwrote in message
news:eY******** ******@TK2MSFTN GP04.phx.gbl...
>So, I have to create a separate project to build a dll containing the
shared functions? Is there any example code out there on how to do this?
Or even on building a dll - preferably exposing more than one function?

You make a Class Library project, the class is public, the functions in
the class are public, you compile the Class Library project to make the
DLL, that you set reference to the DLL in your project wanting to use the
Dll, and you insatiate the class object just like any other object to use
its methods.

<http://www.google.com/search?hl=en&q= creating+a+Clas s+Library+proje ct+VB.net&btnG= Google+Search>

You can also include the project in a Solution a .sln with other projects
and set Project Reference to the project so that you can debug functions
being used by the project using the Class Library.


Jan 3 '08 #11

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

Similar topics

5
3350
by: hokiegal99 | last post by:
A few questions about the following code. How would I "wrap" this in a function, and do I need to? Also, how can I make the code smart enough to realize that when a file has 2 or more bad charcters in it, that the code needs to run until all bad characters are gone? For example, if a file has the name "<bad*mac\file" the program has to run 3 times to get all three bad chars out of the file name. The passes look like this:
0
1087
by: Marcos Rodríguez | last post by:
Hello all, I have received a dll from a reseller who sold me a data acquisition equipment and I am trying to use functions from the dll file but I am receiving an uncontrolled exception. Please are there anyone who can show me which are the steps to use functions from a dll file?. Also, are there differents dll files?, and are there more than one method
4
3844
by: sam1967 | last post by:
How do I get a function to return a GMP integer type mpz_t when i try it i get an error message. i am trying mpz_t hooch (int x) { mpz_t y; ........
3
2889
by: bxstylez | last post by:
rewrite this program (sum,average) using functions, possibly arrays? #include<stdlib.h> #include<stdio.h> main() { FILE *finpt, *foutpt;
1
1325
by: Nathan Sokalski | last post by:
I have a Visual Studio Solution that contains multiple ASP.NET Projects. I do not want to put all of the pages (*.aspx files) in the root directory of my site, because that would be very disorganized. However, I am having trouble getting any projects other than the one that I place in the root directory to work. What extra steps do I need to take to place a project in a directory other than the root? I am using a webhosting service...
1
1932
by: gdarian216 | last post by:
I am reading in different names and scores from a file. I have created a struct that is made up of arrays and a string. Im tring to but the string and scores in the correct array by using a function. I am having trouble and im stuck if anyone can provide some insight I would appreciate it. this is what i have so far..... #include <iostream> #include <string> #include <vector> #include <fstream>
3
2161
by: Manikandan | last post by:
Hi, I'm copying projects from a solution in the vss. In my local system i created solution ,added that project(make modification related to solution) When i added this solution to vss, projects are referred to the original solution not from my new solution I will explain more clearly i have project folder in vss(v4.5) v4.5(folder) project1(project)
1
1214
by: pcatton | last post by:
I have the situation where I have a lot of large databases that use a lot of the same functions. These prove very difficult to maintain and so I was wondering if anyone knew if it is possible to use external database functions. I know this is possible in the VBA code using references and whilst this is good what I would really like to be able to do is use external functions in queries as well. The only way I have found of doing this is to...
3
2904
by: TamaThps | last post by:
I have to write a program that lets the user play the game of Craps. As of right now it is incomplete and I have run into some errors. It's my first time using functions instead of the program all being in the int main(). I am using visual studio on windows XP. In my code I've defined a local variable in a function but when I run the program and it gets to that function it says I have an undeclared variable. The code for the program...
0
10578
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
10332
jinu1996
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...
1
10321
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10077
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
7620
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
5651
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4300
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
2
3820
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2991
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.