E10.2 BeforeFieldChange on Multiple Datasets in Dashboard


I’m customizing a dashboard with multiple queries and need to check BeforeFieldChanged for a column on each of the different datasets.

The first query dataset works okay with the Results dataview. I’m trying to add code to check the remaining datasets, but I get this error:

----------errors and warnings------------

Error: CS1061 - line 97 (715) - ‘Script’ does not contain a definition for ‘edvResultsLS_Column’ and no extension method ‘edvResultsLS_Column’ accepting a first argument of type ‘Script’ could be found (are you missing a using directive or an assembly reference?)

** Compile Failed. **

Line 97 is the last line of this code (unrelated rows omitted for brevity):

// **************************************************
// Custom code for MainController
// Created: 4/2/2018 11:55:10 AM
// **************************************************
using System;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Windows.Forms;
using Ice.BO;
using Ice.UI;
using Ice.Lib;
using Ice.Adapters;
using Ice.Lib.Customization;
using Ice.Lib.ExtendedProps;
using Ice.Lib.Framework;
using Ice.Lib.Searches;
using Ice.UI.FormFunctions;

//using System.Collections.Generic; //added
//using System.IO; //added
//using System.Text; //added

public class Script
// ** Wizard Insert Location - Do Not Remove ‘Begin/End Wizard Added Module Level Variables’ Comments! **
// Begin Wizard Added Module Level Variables **

// End Wizard Added Module Level Variables **

// Add Custom Module Level Variables Here **

private EpiDataView edvResultsLS;

public void InitializeCustomCode()
	// ** Wizard Insert Location - Do not delete 'Begin/End Wizard Added Variable Initialization' lines **
	// Begin Wizard Added Variable Initialization

	this.edvResultsLS_Column.ColumnChanging += new DataColumnChangeEventHandler(this.edvResultsLS_BeforeFieldChange);

I have similar code for Erp.xxxxxx views running in other applications, but not in a dashboard.

Am I missing a “using” or an adapter? The only custom adapter reference is Ice.Contracts.BO.DynamicQuery.

Is there an easier way to reference the dataviews?

Thanks for any assistance.