Hi, I use QLibrary, and have some problem with action.
It's my code:
1.In *.dll
void LOADEROBJSHARED_EXPORT kamil()
{}
void LOADEROBJSHARED_EXPORT kamil()
{}
To copy to clipboard, switch view to plain text mode
2. In app
typedef void (*AvgFunction)();
library.load();
AvgFunction avg = (AvgFunction) library.resolve("kamil");
if (avg)
kamil.setText("good");
else
kamil.setText("bad");
kamil.exec();
typedef void (*AvgFunction)();
QMessageBox kamil;
QLibrary library("LoaderObj.dll");
library.load();
AvgFunction avg = (AvgFunction) library.resolve("kamil");
if (avg)
kamil.setText("good");
else
kamil.setText("bad");
kamil.exec();
To copy to clipboard, switch view to plain text mode
Why it don't laod my function while load library? ;/
Bookmarks