//Initialize collection arrays void Analog_Attach(object sender, AttachEventArgs e) { //4 channels channels = new AnalogChannelCollection(this, 4); foreach (AnalogChannel channel in channels) { channel.voltageMax = 10.0; channel.voltageMin = -10.0; //channel.Voltage = 0; } }
//Nullify collection arrays void Analog_Detach(object sender, DetachEventArgs e) { channels = null; }