473,779 Members | 2,058 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Calling to external DLLs while developing in VB6

Banfa
9,065 Recognized Expert Moderator Expert
The situation is this I have a VB program and a DLL writen in C. The DLL and executable both get built to the same location and work fine when the executable is run. This is also the directory that contains the VB source code and project files.

However I now need to alter the VB program, when I load the project into VB6 and press the run button I get error 53 (file not found) on the DLL file despite the fact that it actually resides in the directory that is both the source and output directory for this VB project.


Opinion in my project team is that the VB IDE is probably executing the code within it's own process and therefore to find the DLL it would either have to be in the same directory as the VB executables or the windows system directory or a directory that is in the PATH environment variable.

We can find no way of specifying in the project the location of the DLL or the location in which to run th program during debugging.

Is all this correct?

For reference this is how we have declared the functions

Expand|Select|Wrap|Line Numbers
  1. Public Declare Function CommsInitialise Lib "SCMCI_COMMS.dll" ( _
  2.         ByRef EventFlag As Long, _
  3.         ByRef TxLED As Long, _
  4.         ByRef RxLED As Long _
  5.         ) As Long
  6.  
Oct 3 '07 #1
1 2591
Telboy
1 New Member
if you ty to compile your VB project, does it ? also what is the path for the compiled exe ? try putting the dll in the same area.
Oct 5 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
2412
by: Matora Nickolay | last post by:
Hello. My program has to use third party components located in several external libraries. Those components, also as my program, are usually been changed. The problem is to make my program use newest versions of external dlls, when they were during my program compilation. As far as I know, there are only 2 methods of using components storied in external dlls: 1. Just setting reference to those libraries. But it does not solve the
3
2117
by: mdaetwyler | last post by:
Hi all I am trying to call a DB/2 v8.2 stored procedure from Perl DBI and am getting an error message telling me, that the routine could not be found in the library path. SQL0444N Routine "*_deposit" (specific name "SQL050519190148810") is implemented with code in library or path "\finban.cac_deposit", function "finban.cac_deposit" which cannot be accessed. Reason code: "4". SQLSTATE=42724
5
1391
by: Joerg M. Colberg | last post by:
My apologies if this is a trivial problem. I have been trying to solve this for a few days now and I just can't get it done. Here's what I have. I have a C++ project in VisualStudio.NET whose code relies on external C code (GNU Scientific Library). That external code I added using Configuration Properties->Linker->Input->Additional Dependencies There, I specified two .lib files and the code compiles just fine. However, when it generates...
11
543
by: RichN | last post by:
I am developing a c program in Visual Studio .NET 2003. I also have an Intel(R) Fortran compiler for MVS .NET My fortran sourcecode already existed. I started a new fortran project and chose to create a dynamic link library. The beginning of the fortran code looks like: SUBROUTINE SFTCK3 !DEC$ ATTRIBUTES DLLEXPORT::SFTCK3
0
3228
by: ZMan | last post by:
Scenario: This is about debugging server side scripts that make calls to middle-tier business DLLs. The server side scripts are legacy ASP 3.0 pages, and the DLLs are managed DLLs converted/developed with VB.NET. What I want from debugging is to be able to step into the methods in the DLLs called from ASP scripts using Visual Studio .NET. Background: For typical script debugging issues, you can read and follow the two documents on...
6
1709
by: Amjad | last post by:
Hi, I want to make a project that calls and executes a function (VB code) made in a seperate file in the Application Folder. I know I can create the function in my project and call it internally, but I want to put the function's code in an external file, so that future updates to the function will require a replacing the function file instead of re-installing the whole project. Can you give me ideas on how I can make small updates to my...
1
2701
by: Dominic via DotNetMonster.com | last post by:
I am a CA-OpenROAD programmer, but I attempting to build some VB.NET DLLs and access them through OpenROAD as an external Windows TypeLib. I have managed to build a simple DLL (code follows) but the only method that I can see exposed is "DisplayNumber" which is a sub declared in a public interface definition rather than "DisplayNumbers" which is the name of the public sub based on the interface definition. My problem is when I attempt...
3
1721
by: Brian Bischof | last post by:
I'm having troubles getting the debugging process to work consistenly for external classes. I got it to work once and then I turned it off. But now I can't get re-enabled. Here is what I'm doing. If someone could tell me what I'm missing that would be great. 1. Create an external class and call it Test.dll. 2. Create a test Asp.net app called App.sln. 3. For App.sln I set a reference to Test.dll. 4. Compile App.sln and run it. The web...
3
2717
by: gopal | last post by:
I am developing an application in CSharp - windows forms based, which copies the DLLs both unmanaged and managed DLLs from a shared folder and will overwrite the existing versions of managed & unmanaged DLLs into folder where some .NET application and a VB application has been installed. To be more clear, i will make some chnages to DLLs and using this tool(developed in CSharp) i will overwrite the existing version of DLLs - unmanaged...
0
1115
by: Echo | last post by:
Hi All: Does somebody know why everytime when we update our website, if there is DLLs involved(we are running VS 2003, .net Framework 1.1, the DLLs is for project or referenced external DLLs, exp: myProject.dll and UrlRewriterForMyProject.dll), it always throw around 100 of following error: System.Web.HttpException: External component has thrown an exception. ---> System.Web.HttpCompileException: External component has thrown an...
0
9474
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
10306
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...
1
10074
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
9930
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
7485
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
6724
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
5503
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3632
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2869
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.