参数与所需类型不兼容

Argument is incompatible with required type

我正在尝试将一些参数从 1 class 传递到另一个,从 custom CustTable Event Handler 传递到 custom Document Matrix class

我想通过客户邮箱,我正在使用:

DirParty::primaryElectronicAddress(custTable.Party, LogisticsElectronicAddressMethodType::Email)

并将其传递给字符串 EDT。

这给了我错误:

Argument is incompatible with required type

如何更改参数传递,以便将返回值填充到字符串 EDT 中?

这个函数DirParty::primaryElectronicAddress(custTable.Party, LogisticsElectronicAddressMethodType::Email)returnLogisticsElectronicAddress

如果您尝试获取电子邮件的值,请尝试以下操作:

LogisticsElectronicAddressLocator _LogisticsElectronicAddressLocator;
LogisticsElectronicAddress        _LogisticsElectronicAddress;

;

_LogisticsElectronicAddress = DirParty::primaryElectronicAddress(custTable.Party, LogisticsElectronicAddressMethodType::Email);
_LogisticsElectronicAddressLocator = _LogisticsElectronicAddress.locator; //E-mail value

如果您想获取客户的电子邮件,您可以使用:

CustTable custTable;

custTable.email();

email() 方法 returns 客户的主要电子邮件。如果您需要其他电子邮件而不是主要电子邮件,您可以在 email() 方法中检查它是如何完成的。

此致, 克里斯蒂安