Daren Chandisingh
April 8th, 1999, 03:44 AM
I have an object based on a template class. I can't nail the syntax required to pass that object as an argument to my function. Please can someone educate me.
---
CArray<int, int> arrayStaff();
GetStaffList(iID, arrayStaff);
...
void CReportExtension::GetStaffList(int iID, CArray<int, int> &arrayStaff)
---
D:\Projects\report\report.cpp(2023) : error C2664: 'GetStaffList' : cannot convert parameter 2 from 'class CArray<int,int> (void)' to 'class CArray<int,int> &'
Context does not allow for disambiguation of overloaded function
--
Daren Chandisingh
---
CArray<int, int> arrayStaff();
GetStaffList(iID, arrayStaff);
...
void CReportExtension::GetStaffList(int iID, CArray<int, int> &arrayStaff)
---
D:\Projects\report\report.cpp(2023) : error C2664: 'GetStaffList' : cannot convert parameter 2 from 'class CArray<int,int> (void)' to 'class CArray<int,int> &'
Context does not allow for disambiguation of overloaded function
--
Daren Chandisingh