I have something like the code below and want to calculate the the mean for the parameter 'value' in column d, using a calculatemean() method that returns a value to the sheet.
please how can i go about it?
- static void AddPropertyToWorksheet(float size,string suburb,string city, float value)
- {
- int row = 2;
- Excel.Worksheet Property_info = workbook.Worksheets[1];
- while (true)
- {
- if (Property_info.Cells[row, "A"].Value == null)
- {
- Property_info.Cells[row, "A"] = size;
- Property_info.Cells[row, "B"] = suburb;
- Property_info.Cells[row, "C"] = city;
- Property_info.Cells[row, "D"] = value;
- return;