Created
May 30, 2018 16:20
-
-
Save LivingInSyn/ee19783b5eb848317440e1dd50860a94 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "stdafx.h" | |
#include "TranslateOutput.h" | |
typedef SomeStruct(CALLBACK* GetSomeStructType)(); | |
int main() | |
{ | |
HINSTANCE dllHandle = NULL; | |
dllHandle = LoadLibrary(L"translator_test.dll"); | |
GetSomeStructType GetSomeStructPtr = NULL; | |
if (dllHandle != NULL) | |
{ | |
GetSomeStructPtr = (GetSomeStructType)GetProcAddress(dllHandle, "GetSomeStruct"); | |
SomeStruct somestruct = GetSomeStructPtr(); | |
printf("Val of foo is %d", somestruct.foo); | |
} | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment