By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,665 Members | 1,900 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,665 IT Pros & Developers. It's quick & easy.

No Entry Point Found In Dll

P: 1

I have a dll that was developed in VC ++.
I need to call the API in C#.
But on run timr iu get an error that no entry point found for function ... in DLL.

and when trying to call the function TApiInitialize or any other function i get an error.

My code in c# is :
public static extern void TApiShutDown();

public void test()



Please advise !!!!

I have the h. file:

// TickerApi function pointer declarations
typedef int (WINAPI* pTApiInitialize)(int);
typedef void (WINAPI* pTApiShutDown)(void);
typedef int (WINAPI* pTApiReadRecord)(BYTE*);
typedef int (WINAPI* pTApiConvertRecord)(BYTE*, BYTE*, int);
typedef int (WINAPI* pTApiReadAndDropRecord)(void);
typedef char* (WINAPI* pTApiGetEag2TfVersion)(void);
typedef char* (WINAPI* pTApiGetFeedServerVersion)(void);
typedef char* (WINAPI* pTApiGetRpcVersion)(void);
typedef char* (WINAPI* pTApiGetVersion)(void);
typedef void (WINAPI* pTApiSaveDataToFile)(int, char*);
typedef int (WINAPI* pTApiEmulateFeedServer)(char*);
typedef int (WINAPI* pTApiRealtimeFeedServer)(void);
typedef void (WINAPI* pTApiSetReadDelay)(long);
typedef double (WINAPI* pTApiFracToDouble)(TfValue*);
typedef long (WINAPI* pTApiFracToDenom)(TfValue*);
typedef long (WINAPI* pTApiFracToNumerator)(TfValue*);
typedef void (WINAPI* pTApiSetPrintf)(int(*)(char*, ...));
typedef void (WINAPI* pTApiSetMarketFlag)(int, int);
typedef void (WINAPI* pTApiSetNewsFlag)(int, int);
typedef void (WINAPI* pTApiSetMessageFlag)(int, int);
typedef void (WINAPI* pTApiSetSecurityFlag)(int, int);
typedef void (WINAPI* pTApiSetFieldFlag)(int, int);
typedef long (WINAPI* pTApiFieldToLong)(TfField*);
typedef float (WINAPI* pTApiFieldToFloat)(TfField*);
typedef double (WINAPI* pTApiFieldToDouble)(TfField*);
typedef int (WINAPI* pTApiFieldToString)(TfField*, char *);
typedef int (WINAPI* pTApiFieldToBinary)(TfField*, char *, int);
typedef int (WINAPI* pTApiConvJulianDate)(DWORD , int *, int *, int *);
typedef TfField *(WINAPI* pTApiGetNextField)(TfPacket*,TfField*);
typedef int (WINAPI* pTApiGetMessageType)(TfPacket *);
typedef int (WINAPI* pTApiGetSecurityType)(TfPacket *);
typedef int (WINAPI* pTApiGetExchangeId)(TfPacket *);
typedef int (WINAPI* pTApiGetMarketCenter)(TfPacket *);
typedef int (WINAPI* pTApiGetFieldCount)(TfPacket *);
typedef int (WINAPI* pTApiGetSymbol)(TfPacket *, char *);
typedef int (WINAPI* pTApiGetFieldId)(TfField *);
typedef int (WINAPI* pTApiGetValueType)(TfField *);
typedef int (WINAPI* pTApiGetValueBuffer)(TfField *, int *, int *, void *);
typedef void (WINAPI* pTApiLoadFeedFile)(char *);
typedef int (WINAPI* pTApiSendCommand)(char *);
typedef int (WINAPI* pTApiPtrToOff) (char *);
typedef int (WINAPI* pTApiOffToPtr) (char *);
typedef int (WINAPI* pTApiDataToString) (char *, char *, int);
typedef int (WINAPI* pTApiDataToXml) (char *, char *, int);

// ClientApi function pointer declarations
typedef int (WINAPI* pCApiInitialize)(int);
typedef void (WINAPI* pCApiShutDown)(void);
typedef void (WINAPI* pCApiSymbolRequest)(TfCApiSymbolRequest *pRequest);
typedef void (WINAPI* pCApiDbaseRequest)(TfCApiDbaseRequest *pRequest);

// ServerApi function pointer declarations
typedef int (WINAPI* pSApiInitialize)(char *, char *, char *, int, int);
typedef void (WINAPI* pSApiShutDown)(void);
typedef char * (WINAPI* pSApiGetLastError)(void);

/* TApiInitialize
* Initialize and enable the communication with the feed server
* nMaxBufSize - the max size (in bytes) of the conversion buffer
* supplied by the main application.
* A default of 4096 bytes is assumed if the parameter
* is set to 0.
* return value - 1 on success
* 0 on any failure
__declspec(dllexport) int WINAPI TApiInitialize (int nMaxBufSize);

/* TApiShutDown
* Disable the communication with the feed server.
* It does NOT shut down the program on the feed server, any subsequent
* call to TApiInitialize() will enable the communication again.
__declspec(dllexport) void WINAPI TApiShutDown (void);
Jan 14 '08 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.