Avatar of GeneBe
GeneBe
Flag for United States of America asked on

Callin DLL in Project B from Project A

C# Project A is calling a DLL in Project B. Project B has Nuget package installed for OracleManagedDataAccess. All in does is make the oracle connection to database. Project A does the select command and puts the data in the grid. Will this work? and does Project A need the Nuget package for OracleManagedDataAccess installed as well?
DatabasesC#* dll

Avatar of undefined
Last Comment
GeneBe

8/22/2022 - Mon
Chinmay Patel

Yes. Because you are running select commands from Project A, you will have to add references. If you move all the data access to Project B and simply call those functions, you will not need explicit references in Project A.
ste5an

As Chinmay wrote: It will work.

But: A single library just for making a connection? This sounds not very reasonable.
Eduard Ghergu

Hi,
If your Project B can be seen as a repository that will abstract the data access details, it makes sense to have this design. If not, maybe you can provide more details about your architecture in order to be able to help.
Your help has saved me hundreds of hours of internet surfing.
fblack61
GeneBe

ASKER
I have a whole bunch of applications that will be calling the Project B DLL. I has a bunch of functions already there, not just the database connection
ASKER CERTIFIED SOLUTION
Eduard Ghergu

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
GeneBe

ASKER
Thank you all!