Yes, there is a header file. I've added that to the top of my .prg but still get the same error message.
The header file is rather long so here is the portion of the header file that pertains to the function I'm trying to use. If you need the whole .h file let me know.
typedef struct _SMSPROVIDERW
{
INT nProviderId;
INT nCountryCode;
INT nRegionCode;
INT nMessageLength;
DWORD dwFlags;
DWORD dwReserved;
WCHAR szGuid[SMS_MAXPROVIDERGUIDLEN];
WCHAR szName[SMS_MAXPROVIDERNAMELEN];
WCHAR szCompany[SMS_MAXCOMPANYNAMELEN];
WCHAR szDomain[SMS_MAXDOMAINNAMELEN];
} SMSPROVIDERW, *LPSMSPROVIDERW;
typedef struct _SMSPROVIDERA
{
INT nProviderId;
INT nCountryCode;
INT nRegionCode;
INT nMessageLength;
DWORD dwFlags;
DWORD dwReserved;
CHAR szGuid[SMS_MAXPROVIDERGUIDLEN];
CHAR szName[SMS_MAXPROVIDERNAMELEN];
CHAR szCompany[SMS_MAXCOMPANYNAMELEN];
CHAR szDomain[SMS_MAXDOMAINNAMELEN];
} SMSPROVIDERA, *LPSMSPROVIDERA;
#ifdef UNICODE
#define SMSPROVIDER SMSPROVIDERW
#define LPSMSPROVIDER LPSMSPROVIDERW
#else
#define SMSPROVIDER SMSPROVIDERA
#define LPSMSPROVIDER LPSMSPROVIDERA
#endif
Here are the functions defined in the .h file...
PUBLIC INT WINAPI SmsGetProviderW(
IN LPCWSTR lpszPhoneNumber,
OUT LPSMSPROVIDERW lpProvider
);
PUBLIC INT WINAPI SmsGetProviderA(
IN LPCSTR lpszPhoneNumber,
OUT LPSMSPROVIDERA lpProvider
);
#ifdef UNICODE
#define SmsGetProvider SmsGetProviderW
#else
#define SmsGetProvider SmsGetProviderA
#endif
I have tried changing the function name to include A or W as above but still get the same error.
xLINK: error: Unresolved external symbol '_SmsGetProviderW referenced from (Testsms.obj)'.
Thanks,
Randal
↧