Click here to Skip to main content
15,884,177 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I am having a VC++ dll which is used to create GUID for our application.
The VC++ funciton is given below. The name of the dll is GUIDDll.dll. The function used to call is "metodo".
C++
CString metodo(CString &strGUID,short ID)
{
    ACNCreateNewGUID(strGUID,ID);
    return strGUID;
}

The input parameter is ID and the output parameter is strGUID. Can anyone please tell me how to call the function "metodo" from vb.net. If possible, please share me sample code snippet to call the function.

When I am trying to call this function, it is throwing an error "Unable to find out the entry point of the dll GUIDDll.dll".

Thanks,
Sivakumar.M.
Posted
Updated 14-Sep-10 6:02am
v2

You are really the first one here to encounter this problem ;P

Have a look:
http://www.codeproject.com/script/Answers/List.aspx?kw=call+c+dll+from+v[^]

Good luck!
 
Share this answer
 
Comments
sivakumar.mariappan 14-Sep-10 10:15am    
Sorry i am not able to access the link you have given. throwing a message like below.

"Sorry, no entries were found matching keywords call c dll from "

Thanks,
Sivakumar.M.
E.F. Nijboer 16-Sep-10 12:46pm    
The search phrase wasn't completely preserved. Try a search on codeproject.com with "call c dll from vb.net" and/or "call c++ dll from vb.net". This will give you better results :-)
You need to learn about pInvoke. The topic is too broad and lengthy to discuss in an answer here. Have you tried googling it?
 
Share this answer
 
Comments
sivakumar.mariappan 15-Sep-10 8:59am    
Thanks to everybody. This issue has been fixed.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900