I am trying to access my list in a webservice but i receive an error
Error 7 'System.Array' does not contain a definition for 'Add' and no extension method 'Add' accepting a first argument of type 'System.Array' could be found (are you missing a using directive or an assembly reference?) C:\Users\kacobilla\Desktop\[email protected]\Clearance System\OCMS_AuditTrailPage.aspx.cs 87 53 C:\...\Clearance System\
my class is named auditclass
auditclass.MyObjectVariableList.Add(DBNull.Value);
this is in my webservice
private List<object> _myObjectVariableList = new List<object>();
public List<object> MyObjectVariableList
{
get { return _myObjectVariableList; }
set { _myObjectVariableList = value; }
}
take note. i am using VS 2005 .net2.0
you have List on server side but when you add reference to that service you get array of items. you can change this behavior while you adding service. check below SO post