jbc1 Posted August 31, 2009 Share Posted August 31, 2009 Hi, I have a problem when using DllCall. It keeps giving me the error, 'Function not found in Dll'. Here is the signiture of the function I am trying to call: PVOID EXPORT WINAPI OpenChannel(void) Here is my AutoIT code: $result = DllCall("caccount.dll", "ptr", "OpenChannel") If @error Then If @error = 1 Then MsgBox(1, "DllCall Error - 1", "Unable to use the DLL file") Return EndIf If @error = 2 Then MsgBox(1, "DllCall Error - 2", "Unknown return type") Return EndIf If @error = 3 Then MsgBox(1, "DllCall Error - 3", "Function not found in the DLL file") Return EndIf Else MsgBox(0, "Num Chars Returned", $result[0]) ; number of chars returned EndIf Can anybody give me some advice on this? Thanks Link to comment Share on other sites More sharing options...
trancexx Posted August 31, 2009 Share Posted August 31, 2009 All is said. There is no such function in caccount.dll.Find some tool to view exported functions. There are at least two posted as AutoIt scripts. One by monoceres (this one) and other by trancexx (yes, that would be me) - link. ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
jbc1 Posted August 31, 2009 Author Share Posted August 31, 2009 All is said. There is no such function in caccount.dll.Find some tool to view exported functions. There are at least two posted as AutoIt scripts. One by monoceres (this one) and other by trancexx (yes, that would be me) - link.I have the actual C++ code, the function does exist. So my AutoIT code is correct? Link to comment Share on other sites More sharing options...
monoceres Posted August 31, 2009 Share Posted August 31, 2009 Are you sure? Try checking with mine or trancexx tool anyway; because if this is the entire function prototype: PVOID EXPORT WINAPI OpenChannel(void) then I suspect you will be surprised when you see what the export viewer actually says. Broken link? PM me and I'll send you the file! Link to comment Share on other sites More sharing options...
trancexx Posted August 31, 2009 Share Posted August 31, 2009 I have the actual C++ code, the function does exist. So my AutoIT code is correct?No, you are wrong. You may have the code but you don't compile it, compiler do. ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
jbc1 Posted August 31, 2009 Author Share Posted August 31, 2009 Are you sure? Try checking with mine or trancexx tool anyway; because if this is the entire function prototype: PVOID EXPORT WINAPI OpenChannel(void) then I suspect you will be surprised when you see what the export viewer actually says. I looked at the DLL using trancexx resource viewer and also PE Explorer, it looks like this under 'Exported Functions' in both applications: _OpenChannel@0 How would I call this correctly? Link to comment Share on other sites More sharing options...
monoceres Posted August 31, 2009 Share Posted August 31, 2009 How would I call this correctly?I have no clue! But whatever you do, DON'T try to use the name of the function the apps gave you. It could blow up your computer. Broken link? PM me and I'll send you the file! Link to comment Share on other sites More sharing options...
trancexx Posted August 31, 2009 Share Posted August 31, 2009 I have no clue! But whatever you do, DON'T try to use the name of the function the apps gave you. It could blow up your computer.Bitchen ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
jbc1 Posted August 31, 2009 Author Share Posted August 31, 2009 BitchenFantastic news Link to comment Share on other sites More sharing options...
ProgAndy Posted August 31, 2009 Share Posted August 31, 2009 (edited) Fantastic newsDid you understand the sarcasm in monoceres' post? Why not simply take the name shown by PEExplorer? Edited August 31, 2009 by ProgAndy *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes Link to comment Share on other sites More sharing options...
trancexx Posted August 31, 2009 Share Posted August 31, 2009 Fantastic newsYou are pregnant? ♡♡♡ . eMyvnE Link to comment Share on other sites More sharing options...
jbc1 Posted August 31, 2009 Author Share Posted August 31, 2009 Did you understand the sarcasm in monoceres' post? Why not simply take the name shown by PEExplorer?Yes I understood it quite well thank you. I find these forums get more immature each time I come. Link to comment Share on other sites More sharing options...
monoceres Posted August 31, 2009 Share Posted August 31, 2009 Yes I understood it quite well thank you. I find these forums get more immature each time I come.How come? Broken link? PM me and I'll send you the file! Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now