I am trying to import a delphi dll and use its method.
Here is the delphi method signature:
function CALinkEncode(SubscriberID, MailshotID, LinkID: DWORD; sCode: PWideChar): HRESULT; stdcall;
Here is the c# code to import the dll and use the function.
[DllImport(@"Decoder.dll", CharSet = CharSet.Ansi)]
static extern string CALinkEncode(
int SubscriberID,
int MailshotID,
int LinkID
);
public static string CALinkDecodeString(int cas, int cam, int cal)
{
string retvalptr = CALinkEncode(cas, cam, cal);
return retvalptr;
}
Please help.