That is not what I said. If you don't have the original header file, create it. That said, if the DLL was written using a different compiler, that won't work either, because different compilers use different schemes for name-mangling.
Why don't you have what you need to use this DLL? It begs the question of whether you should be using it at all. I wouldn't bet my business on unsupported black-box code
Clifford
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
> What is that additional thing required in my main program?
... a header file with the class declaration. The declaration must match that used to build the DLL code. This is usually done by using the same header file.
Clifford
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Okay if that is impossible then I guess COM is the only alternative. Or is it? I am looking for a brief explanation as to how we would make use of COM in the main program. Thanx in advance.
--deostroll
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I am trying to export a class from a dll. I would want to be able to use my class from my main program as a normal class.
The thing I don't understand is, how will my main program be able to use the class when the entire class is declared in the dll...?!
What is that additional thing required in my main program?
--deostroll
Ps: I'm not an advanced c/c++ user
> Okay if that is impossible
That is not what I said. If you don't have the original header file, create it. That said, if the DLL was written using a different compiler, that won't work either, because different compilers use different schemes for name-mangling.
Why don't you have what you need to use this DLL? It begs the question of whether you should be using it at all. I wouldn't bet my business on unsupported black-box code
Clifford
> What is that additional thing required in my main program?
... a header file with the class declaration. The declaration must match that used to build the DLL code. This is usually done by using the same header file.
Clifford
Okay if that is impossible then I guess COM is the only alternative. Or is it? I am looking for a brief explanation as to how we would make use of COM in the main program. Thanx in advance.
--deostroll