Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: VS2008 C#
I have xyz.dll and two header file xyz.hpp and ErrorCode.h
In xyz.hpp
 
#define  FC3_PR_VERSION   "Version" 
typedef void *  FC3_t 
typedef FC3_t  FC3Template_t  
typedef FC3_t  FC3Encode_t  
typedef FC3_t  FC3Match_t  
typedef void DRMAPI  ProgressCallBack_t
(int nPercentCompleted, void *const pUserData) 
 
abcErrorCode_t FC3Initialize (const char *szReserved) 
abcErrorCode_t FC3Uninitialize (void) 
abcErrorCode_t FC3CreateTemplate (FC3Template_t *const pTemplateHandle) 
abcErrorCode_t FC3CreateEncoder (FC3Encode_t *const pEncodeHandle) 
abcErrorCode_t FC3Encode (const FC3Encode_t hEncodeHandle, const BITMAPINFOHEADER *const pBitmapData, const size_t nBitmapSize, const FC3Template_t hTemplate) 
abcErrorCode_t FC3CreateMatcher (FC3Match_t *const pMatchHandle) 
abcErrorCode_t FC3DestroyHandle (FC3_t *const pHandle)
abcErrorCode_t FC3Match (const FC3Match_t hMatchHandle, const FC3Template_t hTemplate1, const FC3Template_t hTemplate2, double *const pdScore)  
and in ErrorCode.h
#define FPC_SUCCESS   0
#define  FPC_ERROR_INITIALIZED   -1 
#define  FPC_ERROR_NOT_INITIALIZED   -2 
#define  FPC_ERROR_NO_LICENCE   -3 
#define  FPC_ERROR_NO_CB_ONEND   -4 
#define  FPC_ERROR_NO_CB_ONERROR   -5 
#define  FPC_ERROR_CODING_LOGGED   -6 
#define  FPC_ERROR_BITMAP_PTR   -10 
#define  FPC_ERROR_BITMAP_COMPRESSION   -31 
#define  FPC_ERROR_BITMAP_HEADERSIZE   -32 
#define  FPC_ERROR_BITMAP_UNEXPECTED_FILEHEADER   -36 
 
typedef long abcErrorCode_t 
I want to call these functions in c#(help me).
Posted 31-Jul-12 19:51pm
Comments
Amund Gjersøe at 1-Aug-12 2:09am
   

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

It's called p.invoke as someone said. Or you can make it a COM dll and call it via COM.
  Permalink  

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

  Print Answers RSS
0 George Jonsson 359
1 Sergey Alexandrovich Kryukov 355
2 CPallini 335
3 BillWoodruff 324
4 OriginalGriff 237
0 OriginalGriff 5,050
1 CPallini 4,225
2 Sergey Alexandrovich Kryukov 3,639
3 George Jonsson 2,911
4 Gihan Liyanage 2,386


Advertise | Privacy | Mobile
Web01 | 2.8.140916.1 | Last Updated 1 Aug 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100