Question
I would like to make a c++ file that simply calls the one function in the .dll file that I need and returns the value. However, I have been trying to use LoadLibrary() to no success at all. When I hover over LoadLibrary, it says "identifier "LoadLibrary" is undefined". I figured that importing windows.h and winbase.h should be enough to define the library...
#pragma once
#include <windows.h>
#include <iostream>
#include <WinBase.h>
#include <E:\Users\Zachary\Anaconda3\include\Python.h>
int main()
{
HINSTANCE dll = LoadLibrary("cbw64.dll");
}
More details about my project design
I am currently working on a senior design project where I have to connect to an OM-USB-TC Data acquisition unit from Omega. Ultimately, all I need to do is get temperature data from this unit and give it to python to do some cool graphing stuff. However, I do not have any communication protocol for this daq as the company is loath to give it out. So, I have to use the universal library that they have provided.
To use the library, I need to import a .dll file. However, it's tricky for python to use this as the temperature data is stored in an in-out variable for programming in c, and it seems like python doesn't play well with in-out variables.