Sign in to follow this  
Followers 0
Shockwave

DllCall help, crashes

2 posts in this topic

#1 ·  Posted (edited)

hi guys,

These is the C++ function am trying to DLLCall

RET_CODE rmsdk_init(const char* resPath)

RET_CODE is an enum, respath is the path of of an ebook,

This code is giving me a crash

$dll = DllOpen("rmsdk_wrapper.dll")
MsgBox(0,"Test",@error)
$path = "C:\Users\ahagarag\Desktop\App\version.epub"
$return = DllCall($dll,"long","rmsdk_init","str",$path)

And also how to write dll call for this function ?

RET_CODE reader_create(const char* docURL, RECORD_TYPE type, READER_HANDLE* handle, char* errorCode, UInt* size)

here READER_HANDLE* is just void* and Uint is unsigned int typdedef
 

Thanks,

Shockwave

Edited by Shockwave

Share this post


Link to post
Share on other sites



Change calling convention to cdecl (help file entry for DllCall explains how).


♡♡♡

.

eMyvnE

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0