?
Solved

Accessing DLLs in multiple directories

Posted on 2004-10-06
4
Medium Priority
?
185 Views
Last Modified: 2010-04-16
Hi, am writing a program using PVCS and PVCS tracker DLLS to attempt to coordinate tracker associated files with their status in PVCS.  the program needs to load the TRKTooln.dll for tracker, and vmwfdk.dll for pvcs.  These DLLs are in their respective program directories, and call other libraries.

I would like to have my program call these DLLS, and have the DLLS be able to call their respective libraries, even though they are in different directories.  Ideally, I would be able to specify the path each DLL is to search as program options, so that the thing could continue to work ,regardless of network drive mapping.

So, how can I tell me program where to go to call these DLLS, and then tell the DLLs where to search to call the libraries that they need?

If it helps, I can call the tracker DLLs first, save information, close my links to tracker, and then call PVCS.

Thanks!
0
Comment
Question by:mitcht
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 6

Expert Comment

by:vadim_ti
ID: 12241319
hi,
you simple have to add path to your dlls to path environment variable
0
 
LVL 6

Expert Comment

by:vadim_ti
ID: 12241431
if you use LoadLibrary function you can save path to your DLL in ini file or registry and retrieve it
before calling LoadLibrary
0
 

Author Comment

by:mitcht
ID: 12242705
OK, I must be really vapor locked, how do I (temporarily) alter the search path?
0
 
LVL 6

Accepted Solution

by:
vadim_ti earned 375 total points
ID: 12242890
if you do not use  dinamic linking (LoadLibrary / FreeLibrary) you cannot change path from your code
you will get exception before you can do anything.
so you will need to change path with windows tools, before execution of your application
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Suggested Courses
Course of the Month11 days, 1 hour left to enroll

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question