I'm using, Xero sdk for my .net project(using Xero.NetStandard.OAuth2.Api;using Xero.NetStandard.OAuth2.Model.PayrollAu;)
public XeroAuth _xeroAuth;
public PayrollAuApi ipayrollAUApi = new PayrollAuApi(); //*************
private Xero.NetStandard.OAuth2.Model.PayrollAu.Employee _GetEmpLeave;
// get perticular Employee all data
private async Task<Xero.NetStandard.OAuth2.Model.PayrollAu.Employee> GetEmployeeAsync(Guid
syncedEmpID)
{
var tokens = await _xeroAuth.GetXeroTokenAuthorization();
_tenantUniqueId = tokens.Item3;
try
{
return ipayrollAUApi.GetEmployeeAsync(tokens.Item1, tokens.Item2,
syncedEmpID).Result._Employees;
}
catch (Exception ex)
{
logging.LoggingToText(ex, await _Context.GetAssemblyInfoAsync(4));
return null;
}
}
in this GetEmployeeAsync method showing casting error it look like this
how to resolve this issue
> GetEmployeeAsync(Guid syncedEmpID)
– erdi yılmaz Sep 16 '21 at 14:39