我下载了一个外国人写的windowsMobile手机TAPI封装类库,有说明文档,下载的内容包含VB.NET演示程序,VB.NET程序要调用DLL工作都正常,我用C#就无论如何都调用不了,具体方法的说明如下:
This function can be used to redirect the offering call to the specified destination address.DWORD NetworkRedirectCall(
   LPCWSTR pwszNumber
); 
Parameters
pwszNumber
[in] Pointer to the null-terminated string that contains the destination address. This follows the standard dialable number format.Return values
Zero indicates success. A non zero number indicates that an error occurred. For additional error information, enable the library debug mode.Res
Call redirect allows an application to deflect an offering call to another address without first answering the call. Redirection can be done on a call-by-call basis by the application, for example, driven by caller ID information. It differs from call transfer in that transferring a call requires the call first be answered. 
After a call has been successfully redirected, the call typically transitions to idle. Requirements
OS Versions: Windows CE 1.0 and later.
Header: dynril.h.
Dll Library: dynrildll.dll.LPCWSTR这种类型不知道在c#里对应的是什么类型。查看了MSDN,看到一篇文章,提到public void M1
([MarshalAs(UnmanagedType.LPWStr)]String msg);
这样调用,根据上面的方法,也没有成功调用成功。里面有一个设置手机免提的函数,因为不需要提供参数,在c#里就可以正常调用。目前问题就是如何正确的提供LPCWSTR pwszNumber参数!请高手指教!