using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.IO;
using WaveLib;
//using Word = Microsoft.Office.Interop.Word;

namespace HearingAidLab
{
	/// <summary>
	/// Summary description for DefEditor.
	/// </summary>
	public class DefEditor : System.Windows.Forms.Form
	{
		private System.ComponentModel.IContainer components;
		/// <summary>
		/// Required designer variable.
		/// </summary>
		#region Component declarations

		private System.Windows.Forms.TabControl tabControl1;
		private System.Windows.Forms.MainMenu mainMenu1;
		private System.Windows.Forms.MenuItem menuItem1;
		private System.Windows.Forms.TabPage tabConstants;
		private System.Windows.Forms.TabPage tabPrimary;
		private System.Windows.Forms.TabPage tabSecondary;
		private System.Windows.Forms.TabPage tabFeedback;
		private System.Windows.Forms.TabPage tabResults;
		private System.Windows.Forms.TabPage tabAdaptive;
		private System.Windows.Forms.TabPage tabButtons;
		private System.Windows.Forms.Label SS1lbl;
		private System.Windows.Forms.Label SS2lbl;
		private System.Windows.Forms.Label SS3lbl;
		private System.Windows.Forms.Label SS4lbl;
		private System.Windows.Forms.TextBox SS1txt;
		private System.Windows.Forms.TextBox SS4txt;
		private System.Windows.Forms.TextBox SS3txt;
		private System.Windows.Forms.TextBox SS2txt;
		private System.Windows.Forms.TextBox SS6txt;
		private System.Windows.Forms.TextBox SS7txt;
		private System.Windows.Forms.TextBox SS8txt;
		private System.Windows.Forms.TextBox SS5txt;
		private System.Windows.Forms.Label SS8lbl;
		private System.Windows.Forms.Label SS7lbl;
		private System.Windows.Forms.Label SS6lbl;
		private System.Windows.Forms.Label SS5lbl;
		private System.Windows.Forms.TextBox PS6txt;
		private System.Windows.Forms.TextBox PS7txt;
		private System.Windows.Forms.TextBox PS8txt;
		private System.Windows.Forms.TextBox PS5txt;
		private System.Windows.Forms.Label PS8lbl;
		private System.Windows.Forms.Label PS7lbl;
		private System.Windows.Forms.Label PS6lbl;
		private System.Windows.Forms.Label PS5lbl;
		private System.Windows.Forms.TextBox PS2txt;
		private System.Windows.Forms.TextBox PS3txt;
		private System.Windows.Forms.TextBox PS4txt;
		private System.Windows.Forms.TextBox PS1txt;
		private System.Windows.Forms.Label PS4lbl;
		private System.Windows.Forms.Label PS3lbl;
		private System.Windows.Forms.Label PS2lbl;
		private System.Windows.Forms.Label PS1lbl;
		private System.Windows.Forms.ListView listPrimary;
		private System.Windows.Forms.RadioButton rdoPsWav;
		private System.Windows.Forms.RadioButton rdoPsPnbn;
		private System.Windows.Forms.RadioButton rdoPsNbn;
		private System.Windows.Forms.RadioButton rdoPsPulse;
		private System.Windows.Forms.RadioButton rdoPsTone;
		private System.Windows.Forms.RadioButton rdoSsWav;
		private System.Windows.Forms.RadioButton rdoSsPnbn;
		private System.Windows.Forms.RadioButton rdoSsNbn;
		private System.Windows.Forms.RadioButton rdoSsPulse;
		private System.Windows.Forms.RadioButton rdoSsTone;
		private System.Windows.Forms.Button btnPSBrowse;
		private System.Windows.Forms.Button btnSSBrowse;
		private System.Windows.Forms.Button btnPSRemove;
		private System.Windows.Forms.Button btnPSAdd;
		private System.Windows.Forms.Button btnSSRemove;
		private System.Windows.Forms.Button btnSSAdd;
		private System.Windows.Forms.Button btnPSUpdate;
		private System.Windows.Forms.Button btnSSUpdate;
		private System.Windows.Forms.Label label1;
		private System.Windows.Forms.Label label2;
		private System.Windows.Forms.Label label3;
		private System.Windows.Forms.Label label4;
		private System.Windows.Forms.Label label5;
		private System.Windows.Forms.Label label6;
		private System.Windows.Forms.Label label7;
		private System.Windows.Forms.Label label8;
		private System.Windows.Forms.TextBox BtnXSize;
		private System.Windows.Forms.TextBox BtnXLoc;
		private System.Windows.Forms.TextBox BtnYSize;
		private System.Windows.Forms.TextBox BtnYLoc;
		private System.Windows.Forms.TextBox BtnFontSize;
		private System.Windows.Forms.TextBox BtnResponseCat;
		private System.Windows.Forms.TextBox BtnText;
		private System.Windows.Forms.TextBox BtnPic;
		private System.Windows.Forms.Button BtnUpdate;
		private System.Windows.Forms.Button BtnRemove;
		private System.Windows.Forms.Button BtnAdd;
		private System.Windows.Forms.Button btnBtnBrowse;
		private System.Windows.Forms.ListView listButtons;
		private System.Windows.Forms.Label label9;
		private System.Windows.Forms.Button btnFeedbackAdd;
		private System.Windows.Forms.Button btnFeedbackRemove;
		private System.Windows.Forms.ListView listFeedback;
		private System.Windows.Forms.GroupBox groupBox1;
		private System.Windows.Forms.RadioButton ResPerf;
		private System.Windows.Forms.RadioButton ResFreq;
		private System.Windows.Forms.CheckBox ResEar;
		private System.Windows.Forms.CheckBox ResMethod;
		private System.Windows.Forms.CheckBox ResPrimary;
		private System.Windows.Forms.CheckBox ResSecondary;
		private System.Windows.Forms.CheckBox ResStimCat;
		private System.Windows.Forms.CheckBox ResAltCat;
		private System.Windows.Forms.ComboBox StopMode;
		private System.Windows.Forms.ComboBox OnCorrect;
		private System.Windows.Forms.TextBox NumOfStopReversals;
		private System.Windows.Forms.TextBox NumOfReversals;
		private System.Windows.Forms.TextBox StandardError;
		private System.Windows.Forms.TextBox SecondaryStep;
		private System.Windows.Forms.TextBox PrimaryStep;
		private System.Windows.Forms.ComboBox Method;
		private System.Windows.Forms.ComboBox Adaptive;
		private System.Windows.Forms.ComboBox PrimaryOrder;
		private System.Windows.Forms.ComboBox Interval;
		private System.Windows.Forms.ComboBox CatchTrials;
		private System.Windows.Forms.ComboBox Cue;
		private System.Windows.Forms.ComboBox WaitForNext;
		private System.Windows.Forms.ComboBox SecondaryContinuous;
		private System.Windows.Forms.ComboBox SecondaryOrder;
		private System.Windows.Forms.TextBox IntervalSpace;
		private System.Windows.Forms.TextBox IntervalLength;
		private System.Windows.Forms.TextBox Reps;
		private System.Windows.Forms.TextBox Range;
		private System.Windows.Forms.TextBox StepSize;
		private System.Windows.Forms.TextBox CatchFreq;
		private System.Windows.Forms.TextBox CatchLength;
		private System.Windows.Forms.TextBox Jitter;
		private System.Windows.Forms.TextBox ISI;
		private System.Windows.Forms.TextBox Timer;
		private System.Windows.Forms.TextBox GameDelay;
		private System.Windows.Forms.TextBox MaxTrials;
		private System.Windows.Forms.TextBox MaxLevel;
		private System.Windows.Forms.LinkLabel linkIntervalSpace;
		private System.Windows.Forms.LinkLabel linkIntervalLength;
		private System.Windows.Forms.LinkLabel linkInterval;
		private System.Windows.Forms.LinkLabel linkReps;
		private System.Windows.Forms.LinkLabel linkRange;
		private System.Windows.Forms.LinkLabel linkStepSize;
		private System.Windows.Forms.LinkLabel linkCatchFreq;
		private System.Windows.Forms.LinkLabel linkCatchLength;
		private System.Windows.Forms.LinkLabel linkCatchTrials;
		private System.Windows.Forms.LinkLabel linkCue;
		private System.Windows.Forms.LinkLabel LinkWaitForNext;
		private System.Windows.Forms.LinkLabel linkJitter;
		private System.Windows.Forms.LinkLabel linkIsi;
		private System.Windows.Forms.LinkLabel linkTimer;
		private System.Windows.Forms.LinkLabel linkGameDelay;
		private System.Windows.Forms.LinkLabel linkMaxTrials;
		private System.Windows.Forms.LinkLabel linkMaxLevel;
		private System.Windows.Forms.LinkLabel linkSecondaryContinuous;
		private System.Windows.Forms.LinkLabel linkSecondaryOrder;
		private System.Windows.Forms.LinkLabel linkPrimaryOrder;
		private System.Windows.Forms.LinkLabel linkReversalsStop;
		private System.Windows.Forms.LinkLabel linkReversals;
		private System.Windows.Forms.LinkLabel linkStandardError;
		private System.Windows.Forms.LinkLabel linkStopMode;
		private System.Windows.Forms.LinkLabel linkSecondaryStepSize;
		private System.Windows.Forms.LinkLabel linkPrimaryStepSize;
		private System.Windows.Forms.LinkLabel linkOnCorrect;
		private System.Windows.Forms.LinkLabel linkMethod;
		private System.Windows.Forms.LinkLabel linkAdaptive;
		#endregion
		private System.Windows.Forms.MenuItem FileLoad;
		private System.Windows.Forms.MenuItem FileSave;
		public Form1 main;
		private System.Windows.Forms.TextBox txtResults;
		private System.Windows.Forms.MenuItem FileSaveAs;
		private System.Windows.Forms.StatusBar statusBar1;
		private System.Windows.Forms.ToolBar toolBarDef;
		private System.Windows.Forms.ToolBarButton toolBarNew;
		private System.Windows.Forms.ImageList imageListDef;
		private System.Windows.Forms.ToolBarButton toolBarOpen;
		private System.Windows.Forms.ToolBarButton toolBarSave;
		private System.Windows.Forms.MenuItem FileNew;
		private System.Windows.Forms.LinkLabel linkGameDelayType;
		private System.Windows.Forms.ComboBox GameDelayType;
		private System.Windows.Forms.ComboBox BacktoBackCatch;
		public FileInfo SaveFile = null;
		//		Word._Application oWord;
		private System.Windows.Forms.LinkLabel linkBackToBack;
		private System.Windows.Forms.LinkLabel linkPrimaryHelp;
		private System.Windows.Forms.LinkLabel linkSecondaryHelp;
		private System.Windows.Forms.LinkLabel linkButtonsHelp;
		private System.Windows.Forms.LinkLabel linkFeedbackHelp;
		private System.Windows.Forms.LinkLabel linkResultsHelp;
		private System.Windows.Forms.ToolBarButton toolBarButton1;
		private System.Windows.Forms.ToolBarButton toolBarManual;
		private System.Windows.Forms.Button btnPrimaryUp;
		private System.Windows.Forms.Button btnPrimaryDown;
		private System.Windows.Forms.Button btnDownFeedback;
		private System.Windows.Forms.Button btnUpFeedback;
		private System.Windows.Forms.TabPage tabCL;
		private System.Windows.Forms.CheckBox chkCL;
		private System.Windows.Forms.LinkLabel linkLabel1;
		private System.Windows.Forms.LinkLabel linkLabel2;
		private System.Windows.Forms.LinkLabel linkLabel3;
		private System.Windows.Forms.LinkLabel linkLabel4;
		private System.Windows.Forms.ComboBox CLPrimaryOrder;
		private System.Windows.Forms.TextBox CLIsiJitter;
		private System.Windows.Forms.TextBox CLIsi;
		private System.Windows.Forms.TextBox CLMaxLevel;
		private System.Windows.Forms.LinkLabel linkLabel5;
		private System.Windows.Forms.TextBox CLButtons;
		private System.Windows.Forms.TabPage tabComplex;
		private System.Windows.Forms.Button btnComplexRemove;
		private System.Windows.Forms.Button btnComplexAdd;
		private System.Windows.Forms.Label label10;
		private System.Windows.Forms.Label label11;
		private System.Windows.Forms.TreeView treeComplex;
		private System.Windows.Forms.LinkLabel linkLabel7;
		private System.Windows.Forms.ComboBox CLAnchored;
		private System.Windows.Forms.LinkLabel linkLabel6;
		private System.Windows.Forms.ComboBox cmbMixSecondary;
		private System.Windows.Forms.LinkLabel linkMixSecondary;
		private System.Windows.Forms.TabPage tabPaired;
		private System.Windows.Forms.RadioButton rbPairedWave;
		private System.Windows.Forms.LinkLabel lnkPairedHelp;
		private System.Windows.Forms.TextBox txtPairedFolder;
		private System.Windows.Forms.Button btnPairedFolder;
		private System.Windows.Forms.Button btnDownSecondary;
		private System.Windows.Forms.ListView listSecondary;
		private System.Windows.Forms.ListView listPaired;
		private System.Windows.Forms.Button btnPairedUpdate;
		private System.Windows.Forms.Button btnPairedRemove;
		private System.Windows.Forms.Button btnPairedAdd;
		private System.Windows.Forms.Label label12;
		private System.Windows.Forms.Button btnUpSecondary;
		private System.Windows.Forms.Label lblPaired3;
		private System.Windows.Forms.Label lblPaired2;
		private System.Windows.Forms.Label lblPaired1;
		private System.Windows.Forms.Label lblPaired4;
		private System.Windows.Forms.TextBox txtPaired1;
		private System.Windows.Forms.TextBox txtPaired2;
		private System.Windows.Forms.TextBox txtPaired3;
		private System.Windows.Forms.TextBox txtPaired4;
		private System.Windows.Forms.Label label13;
		private System.Windows.Forms.Label label14;
		private System.Windows.Forms.LinkLabel lblFeedbackChange;
		private System.Windows.Forms.TextBox txtChangeFeedback;
		private System.Windows.Forms.GroupBox groupBox2;
		private System.Windows.Forms.Label label15;
		private System.Windows.Forms.Label label16;
		private System.Windows.Forms.TextBox txtFeedX;
		private System.Windows.Forms.TextBox txtFeedY;
		private System.Windows.Forms.Label label17;
		private System.Windows.Forms.TextBox txtFeedWid;
		private System.Windows.Forms.Label label18;
		private System.Windows.Forms.TextBox txtFeedHgt;
		private System.Windows.Forms.CheckBox cbPlayLR;
		private System.Windows.Forms.ComboBox cmbAmpType;
		private System.Windows.Forms.LinkLabel linkLabel8;
		private System.Windows.Forms.ComboBox cmbButtonLayout;
		private System.Windows.Forms.LinkLabel linkLabel9;
		private System.Windows.Forms.ComboBox cmbUseAdaptive;
        private Label PS10lbl;
        private Label PS9lbl;
        private RadioButton rdRms;
        private RadioButton rdPeak;
        private TextBox tbAtteunate;
        private Panel pnlMode;
		private System.Windows.Forms.TextBox CLReps;
		//		Word._Document oDoc;

		public DefEditor()
		{
			//
			// Required for Windows Form Designer support
			//
			InitializeComponent();

			this.Closing += new CancelEventHandler(DefEditor_Closing);

            rdoPsTone.CheckedChanged += new EventHandler(PrimaryStim_CheckedChanged);
            rdoPsPulse.CheckedChanged += new EventHandler(PrimaryStim_CheckedChanged);
            rdoPsNbn.CheckedChanged += new EventHandler(PrimaryStim_CheckedChanged);
            rdoPsPnbn.CheckedChanged += new EventHandler(PrimaryStim_CheckedChanged);
            rdoPsWav.CheckedChanged += new EventHandler(PrimaryStim_CheckedChanged);

			rdoSsTone.CheckedChanged += new EventHandler(SecondaryStim_CheckedChanged);
			rdoSsPulse.CheckedChanged += new EventHandler(SecondaryStim_CheckedChanged);
			rdoSsNbn.CheckedChanged += new EventHandler(SecondaryStim_CheckedChanged);
			rdoSsPnbn.CheckedChanged += new EventHandler(SecondaryStim_CheckedChanged);
			rdoSsWav.CheckedChanged += new EventHandler(SecondaryStim_CheckedChanged);
			rdoPsTone.Checked = true;
			rdoSsTone.Checked = true;
			rbPairedWave.Checked=true;
			DisplayPairedControls();//for paired tab
			listPrimary.Click += new EventHandler(listPrimary_Click);
			listSecondary.Click += new EventHandler(listSecondary_Click);
			listButtons.Click += new EventHandler(listButtons_Click);
			this.tabControl1.SelectedIndexChanged += new EventHandler(tabChanged);

			ResPerf.CheckedChanged += new EventHandler(ResPerf_CheckedChanged);
			ResFreq.CheckedChanged += new EventHandler(ResFreq_CheckedChanged);
			ResEar.CheckedChanged += new EventHandler(ResEar_CheckedChanged);
			ResMethod.CheckedChanged += new EventHandler(ResMethod_CheckedChanged);
			ResPrimary.CheckedChanged += new EventHandler(ResPrimary_CheckedChanged);
			ResSecondary.CheckedChanged += new EventHandler(ResSecondary_CheckedChanged);
			ResStimCat.CheckedChanged += new EventHandler(ResStimCat_CheckedChanged);
			ResAltCat.CheckedChanged += new EventHandler(ResAltCat_CheckedChanged);

			this.CatchTrials.SelectedValueChanged += new EventHandler(CatchTrials_SelectedValueChanged);
			this.Interval.SelectedValueChanged += new EventHandler(Interval_SelectedValueChanged);
			this.Adaptive.SelectedValueChanged += new EventHandler(Adaptive_SelectedValueChanged);
		}

		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if(components != null)
				{
					components.Dispose();
				}
			}
			base.Dispose( disposing );
		}

		#region Windows Form Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		private void InitializeComponent()
		{
            this.components = new System.ComponentModel.Container();
            System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(DefEditor));
            this.tabControl1 = new System.Windows.Forms.TabControl();
            this.tabConstants = new System.Windows.Forms.TabPage();
            this.label14 = new System.Windows.Forms.Label();
            this.txtChangeFeedback = new System.Windows.Forms.TextBox();
            this.lblFeedbackChange = new System.Windows.Forms.LinkLabel();
            this.linkMixSecondary = new System.Windows.Forms.LinkLabel();
            this.cmbMixSecondary = new System.Windows.Forms.ComboBox();
            this.linkBackToBack = new System.Windows.Forms.LinkLabel();
            this.BacktoBackCatch = new System.Windows.Forms.ComboBox();
            this.GameDelayType = new System.Windows.Forms.ComboBox();
            this.linkGameDelayType = new System.Windows.Forms.LinkLabel();
            this.linkIntervalSpace = new System.Windows.Forms.LinkLabel();
            this.linkIntervalLength = new System.Windows.Forms.LinkLabel();
            this.linkInterval = new System.Windows.Forms.LinkLabel();
            this.linkReps = new System.Windows.Forms.LinkLabel();
            this.linkRange = new System.Windows.Forms.LinkLabel();
            this.linkStepSize = new System.Windows.Forms.LinkLabel();
            this.linkCatchFreq = new System.Windows.Forms.LinkLabel();
            this.linkCatchLength = new System.Windows.Forms.LinkLabel();
            this.linkCatchTrials = new System.Windows.Forms.LinkLabel();
            this.linkCue = new System.Windows.Forms.LinkLabel();
            this.LinkWaitForNext = new System.Windows.Forms.LinkLabel();
            this.linkJitter = new System.Windows.Forms.LinkLabel();
            this.linkIsi = new System.Windows.Forms.LinkLabel();
            this.linkTimer = new System.Windows.Forms.LinkLabel();
            this.linkGameDelay = new System.Windows.Forms.LinkLabel();
            this.linkMaxTrials = new System.Windows.Forms.LinkLabel();
            this.linkMaxLevel = new System.Windows.Forms.LinkLabel();
            this.linkSecondaryContinuous = new System.Windows.Forms.LinkLabel();
            this.linkSecondaryOrder = new System.Windows.Forms.LinkLabel();
            this.linkPrimaryOrder = new System.Windows.Forms.LinkLabel();
            this.PrimaryOrder = new System.Windows.Forms.ComboBox();
            this.Interval = new System.Windows.Forms.ComboBox();
            this.CatchTrials = new System.Windows.Forms.ComboBox();
            this.Cue = new System.Windows.Forms.ComboBox();
            this.WaitForNext = new System.Windows.Forms.ComboBox();
            this.SecondaryContinuous = new System.Windows.Forms.ComboBox();
            this.SecondaryOrder = new System.Windows.Forms.ComboBox();
            this.IntervalSpace = new System.Windows.Forms.TextBox();
            this.IntervalLength = new System.Windows.Forms.TextBox();
            this.Reps = new System.Windows.Forms.TextBox();
            this.Range = new System.Windows.Forms.TextBox();
            this.StepSize = new System.Windows.Forms.TextBox();
            this.CatchFreq = new System.Windows.Forms.TextBox();
            this.CatchLength = new System.Windows.Forms.TextBox();
            this.Jitter = new System.Windows.Forms.TextBox();
            this.ISI = new System.Windows.Forms.TextBox();
            this.Timer = new System.Windows.Forms.TextBox();
            this.GameDelay = new System.Windows.Forms.TextBox();
            this.MaxTrials = new System.Windows.Forms.TextBox();
            this.MaxLevel = new System.Windows.Forms.TextBox();
            this.tabCL = new System.Windows.Forms.TabPage();
            this.linkLabel9 = new System.Windows.Forms.LinkLabel();
            this.cmbUseAdaptive = new System.Windows.Forms.ComboBox();
            this.linkLabel8 = new System.Windows.Forms.LinkLabel();
            this.cmbButtonLayout = new System.Windows.Forms.ComboBox();
            this.linkLabel6 = new System.Windows.Forms.LinkLabel();
            this.CLReps = new System.Windows.Forms.TextBox();
            this.linkLabel7 = new System.Windows.Forms.LinkLabel();
            this.CLAnchored = new System.Windows.Forms.ComboBox();
            this.linkLabel5 = new System.Windows.Forms.LinkLabel();
            this.CLButtons = new System.Windows.Forms.TextBox();
            this.linkLabel1 = new System.Windows.Forms.LinkLabel();
            this.linkLabel2 = new System.Windows.Forms.LinkLabel();
            this.linkLabel3 = new System.Windows.Forms.LinkLabel();
            this.linkLabel4 = new System.Windows.Forms.LinkLabel();
            this.CLPrimaryOrder = new System.Windows.Forms.ComboBox();
            this.CLIsiJitter = new System.Windows.Forms.TextBox();
            this.CLIsi = new System.Windows.Forms.TextBox();
            this.CLMaxLevel = new System.Windows.Forms.TextBox();
            this.chkCL = new System.Windows.Forms.CheckBox();
            this.tabPrimary = new System.Windows.Forms.TabPage();
            this.btnPrimaryDown = new System.Windows.Forms.Button();
            this.btnPrimaryUp = new System.Windows.Forms.Button();
            this.linkPrimaryHelp = new System.Windows.Forms.LinkLabel();
            this.btnPSUpdate = new System.Windows.Forms.Button();
            this.btnPSBrowse = new System.Windows.Forms.Button();
            this.btnPSRemove = new System.Windows.Forms.Button();
            this.btnPSAdd = new System.Windows.Forms.Button();
            this.listPrimary = new System.Windows.Forms.ListView();
            this.PS4lbl = new System.Windows.Forms.Label();
            this.PS3lbl = new System.Windows.Forms.Label();
            this.PS2lbl = new System.Windows.Forms.Label();
            this.PS1lbl = new System.Windows.Forms.Label();
            this.PS6txt = new System.Windows.Forms.TextBox();
            this.PS7txt = new System.Windows.Forms.TextBox();
            this.PS8txt = new System.Windows.Forms.TextBox();
            this.PS5txt = new System.Windows.Forms.TextBox();
            this.PS8lbl = new System.Windows.Forms.Label();
            this.PS7lbl = new System.Windows.Forms.Label();
            this.PS6lbl = new System.Windows.Forms.Label();
            this.PS5lbl = new System.Windows.Forms.Label();
            this.PS2txt = new System.Windows.Forms.TextBox();
            this.PS3txt = new System.Windows.Forms.TextBox();
            this.PS4txt = new System.Windows.Forms.TextBox();
            this.PS1txt = new System.Windows.Forms.TextBox();
            this.rdoPsWav = new System.Windows.Forms.RadioButton();
            this.rdoPsPnbn = new System.Windows.Forms.RadioButton();
            this.rdoPsNbn = new System.Windows.Forms.RadioButton();
            this.rdoPsPulse = new System.Windows.Forms.RadioButton();
            this.rdoPsTone = new System.Windows.Forms.RadioButton();
            this.tabSecondary = new System.Windows.Forms.TabPage();
            this.btnDownSecondary = new System.Windows.Forms.Button();
            this.btnUpSecondary = new System.Windows.Forms.Button();
            this.linkSecondaryHelp = new System.Windows.Forms.LinkLabel();
            this.btnSSUpdate = new System.Windows.Forms.Button();
            this.btnSSBrowse = new System.Windows.Forms.Button();
            this.btnSSRemove = new System.Windows.Forms.Button();
            this.btnSSAdd = new System.Windows.Forms.Button();
            this.listSecondary = new System.Windows.Forms.ListView();
            this.SS6txt = new System.Windows.Forms.TextBox();
            this.SS7txt = new System.Windows.Forms.TextBox();
            this.SS8txt = new System.Windows.Forms.TextBox();
            this.SS5txt = new System.Windows.Forms.TextBox();
            this.SS8lbl = new System.Windows.Forms.Label();
            this.SS7lbl = new System.Windows.Forms.Label();
            this.SS6lbl = new System.Windows.Forms.Label();
            this.SS5lbl = new System.Windows.Forms.Label();
            this.SS2txt = new System.Windows.Forms.TextBox();
            this.SS3txt = new System.Windows.Forms.TextBox();
            this.SS4txt = new System.Windows.Forms.TextBox();
            this.SS1txt = new System.Windows.Forms.TextBox();
            this.SS4lbl = new System.Windows.Forms.Label();
            this.SS3lbl = new System.Windows.Forms.Label();
            this.SS2lbl = new System.Windows.Forms.Label();
            this.SS1lbl = new System.Windows.Forms.Label();
            this.rdoSsWav = new System.Windows.Forms.RadioButton();
            this.rdoSsPnbn = new System.Windows.Forms.RadioButton();
            this.rdoSsNbn = new System.Windows.Forms.RadioButton();
            this.rdoSsPulse = new System.Windows.Forms.RadioButton();
            this.rdoSsTone = new System.Windows.Forms.RadioButton();
            this.tabPaired = new System.Windows.Forms.TabPage();
            this.cbPlayLR = new System.Windows.Forms.CheckBox();
            this.label13 = new System.Windows.Forms.Label();
            this.cmbAmpType = new System.Windows.Forms.ComboBox();
            this.txtPaired4 = new System.Windows.Forms.TextBox();
            this.lblPaired4 = new System.Windows.Forms.Label();
            this.label12 = new System.Windows.Forms.Label();
            this.btnPairedUpdate = new System.Windows.Forms.Button();
            this.btnPairedRemove = new System.Windows.Forms.Button();
            this.btnPairedAdd = new System.Windows.Forms.Button();
            this.txtPaired1 = new System.Windows.Forms.TextBox();
            this.txtPaired2 = new System.Windows.Forms.TextBox();
            this.txtPaired3 = new System.Windows.Forms.TextBox();
            this.lblPaired3 = new System.Windows.Forms.Label();
            this.lblPaired2 = new System.Windows.Forms.Label();
            this.lblPaired1 = new System.Windows.Forms.Label();
            this.listPaired = new System.Windows.Forms.ListView();
            this.btnPairedFolder = new System.Windows.Forms.Button();
            this.txtPairedFolder = new System.Windows.Forms.TextBox();
            this.lnkPairedHelp = new System.Windows.Forms.LinkLabel();
            this.rbPairedWave = new System.Windows.Forms.RadioButton();
            this.tabAdaptive = new System.Windows.Forms.TabPage();
            this.linkReversalsStop = new System.Windows.Forms.LinkLabel();
            this.linkReversals = new System.Windows.Forms.LinkLabel();
            this.linkStandardError = new System.Windows.Forms.LinkLabel();
            this.linkStopMode = new System.Windows.Forms.LinkLabel();
            this.linkSecondaryStepSize = new System.Windows.Forms.LinkLabel();
            this.linkPrimaryStepSize = new System.Windows.Forms.LinkLabel();
            this.linkOnCorrect = new System.Windows.Forms.LinkLabel();
            this.linkMethod = new System.Windows.Forms.LinkLabel();
            this.linkAdaptive = new System.Windows.Forms.LinkLabel();
            this.StopMode = new System.Windows.Forms.ComboBox();
            this.OnCorrect = new System.Windows.Forms.ComboBox();
            this.NumOfStopReversals = new System.Windows.Forms.TextBox();
            this.NumOfReversals = new System.Windows.Forms.TextBox();
            this.StandardError = new System.Windows.Forms.TextBox();
            this.SecondaryStep = new System.Windows.Forms.TextBox();
            this.PrimaryStep = new System.Windows.Forms.TextBox();
            this.Method = new System.Windows.Forms.ComboBox();
            this.Adaptive = new System.Windows.Forms.ComboBox();
            this.tabResults = new System.Windows.Forms.TabPage();
            this.linkResultsHelp = new System.Windows.Forms.LinkLabel();
            this.txtResults = new System.Windows.Forms.TextBox();
            this.ResAltCat = new System.Windows.Forms.CheckBox();
            this.ResStimCat = new System.Windows.Forms.CheckBox();
            this.ResSecondary = new System.Windows.Forms.CheckBox();
            this.ResPrimary = new System.Windows.Forms.CheckBox();
            this.ResMethod = new System.Windows.Forms.CheckBox();
            this.ResEar = new System.Windows.Forms.CheckBox();
            this.groupBox1 = new System.Windows.Forms.GroupBox();
            this.ResFreq = new System.Windows.Forms.RadioButton();
            this.ResPerf = new System.Windows.Forms.RadioButton();
            this.tabFeedback = new System.Windows.Forms.TabPage();
            this.groupBox2 = new System.Windows.Forms.GroupBox();
            this.txtFeedHgt = new System.Windows.Forms.TextBox();
            this.label18 = new System.Windows.Forms.Label();
            this.txtFeedWid = new System.Windows.Forms.TextBox();
            this.label17 = new System.Windows.Forms.Label();
            this.txtFeedY = new System.Windows.Forms.TextBox();
            this.txtFeedX = new System.Windows.Forms.TextBox();
            this.label16 = new System.Windows.Forms.Label();
            this.label15 = new System.Windows.Forms.Label();
            this.btnDownFeedback = new System.Windows.Forms.Button();
            this.btnUpFeedback = new System.Windows.Forms.Button();
            this.linkFeedbackHelp = new System.Windows.Forms.LinkLabel();
            this.listFeedback = new System.Windows.Forms.ListView();
            this.btnFeedbackRemove = new System.Windows.Forms.Button();
            this.btnFeedbackAdd = new System.Windows.Forms.Button();
            this.label9 = new System.Windows.Forms.Label();
            this.tabButtons = new System.Windows.Forms.TabPage();
            this.linkButtonsHelp = new System.Windows.Forms.LinkLabel();
            this.btnBtnBrowse = new System.Windows.Forms.Button();
            this.BtnUpdate = new System.Windows.Forms.Button();
            this.BtnRemove = new System.Windows.Forms.Button();
            this.BtnAdd = new System.Windows.Forms.Button();
            this.listButtons = new System.Windows.Forms.ListView();
            this.BtnPic = new System.Windows.Forms.TextBox();
            this.label8 = new System.Windows.Forms.Label();
            this.BtnText = new System.Windows.Forms.TextBox();
            this.label7 = new System.Windows.Forms.Label();
            this.BtnResponseCat = new System.Windows.Forms.TextBox();
            this.label6 = new System.Windows.Forms.Label();
            this.BtnFontSize = new System.Windows.Forms.TextBox();
            this.label5 = new System.Windows.Forms.Label();
            this.BtnYLoc = new System.Windows.Forms.TextBox();
            this.label4 = new System.Windows.Forms.Label();
            this.BtnYSize = new System.Windows.Forms.TextBox();
            this.label3 = new System.Windows.Forms.Label();
            this.BtnXLoc = new System.Windows.Forms.TextBox();
            this.label2 = new System.Windows.Forms.Label();
            this.BtnXSize = new System.Windows.Forms.TextBox();
            this.label1 = new System.Windows.Forms.Label();
            this.tabComplex = new System.Windows.Forms.TabPage();
            this.treeComplex = new System.Windows.Forms.TreeView();
            this.label11 = new System.Windows.Forms.Label();
            this.label10 = new System.Windows.Forms.Label();
            this.btnComplexRemove = new System.Windows.Forms.Button();
            this.btnComplexAdd = new System.Windows.Forms.Button();
            this.mainMenu1 = new System.Windows.Forms.MainMenu(this.components);
            this.menuItem1 = new System.Windows.Forms.MenuItem();
            this.FileNew = new System.Windows.Forms.MenuItem();
            this.FileLoad = new System.Windows.Forms.MenuItem();
            this.FileSave = new System.Windows.Forms.MenuItem();
            this.FileSaveAs = new System.Windows.Forms.MenuItem();
            this.toolBarDef = new System.Windows.Forms.ToolBar();
            this.toolBarNew = new System.Windows.Forms.ToolBarButton();
            this.toolBarOpen = new System.Windows.Forms.ToolBarButton();
            this.toolBarSave = new System.Windows.Forms.ToolBarButton();
            this.toolBarButton1 = new System.Windows.Forms.ToolBarButton();
            this.toolBarManual = new System.Windows.Forms.ToolBarButton();
            this.imageListDef = new System.Windows.Forms.ImageList(this.components);
            this.statusBar1 = new System.Windows.Forms.StatusBar();
            this.PS9lbl = new System.Windows.Forms.Label();
            this.PS10lbl = new System.Windows.Forms.Label();
            this.rdPeak = new System.Windows.Forms.RadioButton();
            this.rdRms = new System.Windows.Forms.RadioButton();
            this.tbAtteunate = new System.Windows.Forms.TextBox();
            this.pnlMode = new System.Windows.Forms.Panel();
            this.tabControl1.SuspendLayout();
            this.tabConstants.SuspendLayout();
            this.tabCL.SuspendLayout();
            this.tabPrimary.SuspendLayout();
            this.tabSecondary.SuspendLayout();
            this.tabPaired.SuspendLayout();
            this.tabAdaptive.SuspendLayout();
            this.tabResults.SuspendLayout();
            this.groupBox1.SuspendLayout();
            this.tabFeedback.SuspendLayout();
            this.groupBox2.SuspendLayout();
            this.tabButtons.SuspendLayout();
            this.tabComplex.SuspendLayout();
            this.pnlMode.SuspendLayout();
            this.SuspendLayout();
            // 
            // tabControl1
            // 
            this.tabControl1.Controls.Add(this.tabConstants);
            this.tabControl1.Controls.Add(this.tabCL);
            this.tabControl1.Controls.Add(this.tabPrimary);
            this.tabControl1.Controls.Add(this.tabSecondary);
            this.tabControl1.Controls.Add(this.tabPaired);
            this.tabControl1.Controls.Add(this.tabAdaptive);
            this.tabControl1.Controls.Add(this.tabResults);
            this.tabControl1.Controls.Add(this.tabFeedback);
            this.tabControl1.Controls.Add(this.tabButtons);
            this.tabControl1.Controls.Add(this.tabComplex);
            this.tabControl1.Location = new System.Drawing.Point(8, 40);
            this.tabControl1.Name = "tabControl1";
            this.tabControl1.SelectedIndex = 0;
            this.tabControl1.Size = new System.Drawing.Size(617, 455);
            this.tabControl1.TabIndex = 0;
            // 
            // tabConstants
            // 
            this.tabConstants.Controls.Add(this.label14);
            this.tabConstants.Controls.Add(this.txtChangeFeedback);
            this.tabConstants.Controls.Add(this.lblFeedbackChange);
            this.tabConstants.Controls.Add(this.linkMixSecondary);
            this.tabConstants.Controls.Add(this.cmbMixSecondary);
            this.tabConstants.Controls.Add(this.linkBackToBack);
            this.tabConstants.Controls.Add(this.BacktoBackCatch);
            this.tabConstants.Controls.Add(this.GameDelayType);
            this.tabConstants.Controls.Add(this.linkGameDelayType);
            this.tabConstants.Controls.Add(this.linkIntervalSpace);
            this.tabConstants.Controls.Add(this.linkIntervalLength);
            this.tabConstants.Controls.Add(this.linkInterval);
            this.tabConstants.Controls.Add(this.linkReps);
            this.tabConstants.Controls.Add(this.linkRange);
            this.tabConstants.Controls.Add(this.linkStepSize);
            this.tabConstants.Controls.Add(this.linkCatchFreq);
            this.tabConstants.Controls.Add(this.linkCatchLength);
            this.tabConstants.Controls.Add(this.linkCatchTrials);
            this.tabConstants.Controls.Add(this.linkCue);
            this.tabConstants.Controls.Add(this.LinkWaitForNext);
            this.tabConstants.Controls.Add(this.linkJitter);
            this.tabConstants.Controls.Add(this.linkIsi);
            this.tabConstants.Controls.Add(this.linkTimer);
            this.tabConstants.Controls.Add(this.linkGameDelay);
            this.tabConstants.Controls.Add(this.linkMaxTrials);
            this.tabConstants.Controls.Add(this.linkMaxLevel);
            this.tabConstants.Controls.Add(this.linkSecondaryContinuous);
            this.tabConstants.Controls.Add(this.linkSecondaryOrder);
            this.tabConstants.Controls.Add(this.linkPrimaryOrder);
            this.tabConstants.Controls.Add(this.PrimaryOrder);
            this.tabConstants.Controls.Add(this.Interval);
            this.tabConstants.Controls.Add(this.CatchTrials);
            this.tabConstants.Controls.Add(this.Cue);
            this.tabConstants.Controls.Add(this.WaitForNext);
            this.tabConstants.Controls.Add(this.SecondaryContinuous);
            this.tabConstants.Controls.Add(this.SecondaryOrder);
            this.tabConstants.Controls.Add(this.IntervalSpace);
            this.tabConstants.Controls.Add(this.IntervalLength);
            this.tabConstants.Controls.Add(this.Reps);
            this.tabConstants.Controls.Add(this.Range);
            this.tabConstants.Controls.Add(this.StepSize);
            this.tabConstants.Controls.Add(this.CatchFreq);
            this.tabConstants.Controls.Add(this.CatchLength);
            this.tabConstants.Controls.Add(this.Jitter);
            this.tabConstants.Controls.Add(this.ISI);
            this.tabConstants.Controls.Add(this.Timer);
            this.tabConstants.Controls.Add(this.GameDelay);
            this.tabConstants.Controls.Add(this.MaxTrials);
            this.tabConstants.Controls.Add(this.MaxLevel);
            this.tabConstants.Location = new System.Drawing.Point(4, 22);
            this.tabConstants.Name = "tabConstants";
            this.tabConstants.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.tabConstants.Size = new System.Drawing.Size(576, 390);
            this.tabConstants.TabIndex = 0;
            this.tabConstants.Text = "Constants";
            // 
            // label14
            // 
            this.label14.Location = new System.Drawing.Point(520, 88);
            this.label14.Name = "label14";
            this.label14.Size = new System.Drawing.Size(54, 16);
            this.label14.TabIndex = 98;
            this.label14.Text = "% of runs";
            this.label14.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
            // 
            // txtChangeFeedback
            // 
            this.txtChangeFeedback.Location = new System.Drawing.Point(424, 248);
            this.txtChangeFeedback.Name = "txtChangeFeedback";
            this.txtChangeFeedback.Size = new System.Drawing.Size(96, 20);
            this.txtChangeFeedback.TabIndex = 97;
            this.txtChangeFeedback.Text = "1";
            // 
            // lblFeedbackChange
            // 
            this.lblFeedbackChange.Location = new System.Drawing.Point(256, 248);
            this.lblFeedbackChange.Name = "lblFeedbackChange";
            this.lblFeedbackChange.Size = new System.Drawing.Size(168, 16);
            this.lblFeedbackChange.TabIndex = 96;
            this.lblFeedbackChange.TabStop = true;
            this.lblFeedbackChange.Text = "Feedback Change Frequency:";
            this.lblFeedbackChange.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // linkMixSecondary
            // 
            this.linkMixSecondary.Location = new System.Drawing.Point(8, 80);
            this.linkMixSecondary.Name = "linkMixSecondary";
            this.linkMixSecondary.RightToLeft = System.Windows.Forms.RightToLeft.No;
            this.linkMixSecondary.Size = new System.Drawing.Size(120, 23);
            this.linkMixSecondary.TabIndex = 95;
            this.linkMixSecondary.TabStop = true;
            this.linkMixSecondary.Text = "Mix Secondary:";
            this.linkMixSecondary.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // cmbMixSecondary
            // 
            this.cmbMixSecondary.Items.AddRange(new object[] {
            "Mix",
            "Do not Mix"});
            this.cmbMixSecondary.Location = new System.Drawing.Point(136, 80);
            this.cmbMixSecondary.Name = "cmbMixSecondary";
            this.cmbMixSecondary.Size = new System.Drawing.Size(100, 21);
            this.cmbMixSecondary.TabIndex = 94;
            this.cmbMixSecondary.Text = "Do not Mix";
            // 
            // linkBackToBack
            // 
            this.linkBackToBack.Location = new System.Drawing.Point(256, 31);
            this.linkBackToBack.Name = "linkBackToBack";
            this.linkBackToBack.Size = new System.Drawing.Size(168, 23);
            this.linkBackToBack.TabIndex = 93;
            this.linkBackToBack.TabStop = true;
            this.linkBackToBack.Text = "Allow Back to Back Catch Trials:";
            this.linkBackToBack.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkBackToBack.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkBackToBack.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // BacktoBackCatch
            // 
            this.BacktoBackCatch.Items.AddRange(new object[] {
            "False",
            "True"});
            this.BacktoBackCatch.Location = new System.Drawing.Point(424, 32);
            this.BacktoBackCatch.Name = "BacktoBackCatch";
            this.BacktoBackCatch.Size = new System.Drawing.Size(100, 21);
            this.BacktoBackCatch.Sorted = true;
            this.BacktoBackCatch.TabIndex = 92;
            this.BacktoBackCatch.Text = "False";
            // 
            // GameDelayType
            // 
            this.GameDelayType.Items.AddRange(new object[] {
            "1 Step every X Trials",
            "Store and Show"});
            this.GameDelayType.Location = new System.Drawing.Point(136, 176);
            this.GameDelayType.Name = "GameDelayType";
            this.GameDelayType.Size = new System.Drawing.Size(100, 21);
            this.GameDelayType.Sorted = true;
            this.GameDelayType.TabIndex = 91;
            this.GameDelayType.Text = "Store and Show";
            // 
            // linkGameDelayType
            // 
            this.linkGameDelayType.Location = new System.Drawing.Point(8, 176);
            this.linkGameDelayType.Name = "linkGameDelayType";
            this.linkGameDelayType.Size = new System.Drawing.Size(128, 23);
            this.linkGameDelayType.TabIndex = 90;
            this.linkGameDelayType.TabStop = true;
            this.linkGameDelayType.Text = "Game Delay Type:";
            this.linkGameDelayType.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkGameDelayType.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkGameDelayType.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkIntervalSpace
            // 
            this.linkIntervalSpace.Location = new System.Drawing.Point(296, 223);
            this.linkIntervalSpace.Name = "linkIntervalSpace";
            this.linkIntervalSpace.Size = new System.Drawing.Size(128, 23);
            this.linkIntervalSpace.TabIndex = 89;
            this.linkIntervalSpace.TabStop = true;
            this.linkIntervalSpace.Text = "ms Between Intervals:";
            this.linkIntervalSpace.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkIntervalSpace.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkIntervalSpace.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkIntervalLength
            // 
            this.linkIntervalLength.Location = new System.Drawing.Point(296, 199);
            this.linkIntervalLength.Name = "linkIntervalLength";
            this.linkIntervalLength.Size = new System.Drawing.Size(128, 23);
            this.linkIntervalLength.TabIndex = 88;
            this.linkIntervalLength.TabStop = true;
            this.linkIntervalLength.Text = "Interval Length (ms):";
            this.linkIntervalLength.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkIntervalLength.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkIntervalLength.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkInterval
            // 
            this.linkInterval.Location = new System.Drawing.Point(296, 175);
            this.linkInterval.Name = "linkInterval";
            this.linkInterval.Size = new System.Drawing.Size(128, 23);
            this.linkInterval.TabIndex = 87;
            this.linkInterval.TabStop = true;
            this.linkInterval.Text = "MIFC:";
            this.linkInterval.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkInterval.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkInterval.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkReps
            // 
            this.linkReps.Location = new System.Drawing.Point(296, 151);
            this.linkReps.Name = "linkReps";
            this.linkReps.Size = new System.Drawing.Size(128, 23);
            this.linkReps.TabIndex = 86;
            this.linkReps.TabStop = true;
            this.linkReps.Text = "Repetitions:";
            this.linkReps.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkReps.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkReps.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkRange
            // 
            this.linkRange.Location = new System.Drawing.Point(296, 127);
            this.linkRange.Name = "linkRange";
            this.linkRange.Size = new System.Drawing.Size(128, 23);
            this.linkRange.TabIndex = 85;
            this.linkRange.TabStop = true;
            this.linkRange.Text = "Range - Total Range:";
            this.linkRange.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkRange.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkRange.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkStepSize
            // 
            this.linkStepSize.Location = new System.Drawing.Point(296, 103);
            this.linkStepSize.Name = "linkStepSize";
            this.linkStepSize.Size = new System.Drawing.Size(128, 23);
            this.linkStepSize.TabIndex = 84;
            this.linkStepSize.TabStop = true;
            this.linkStepSize.Text = "Range - Step Size:";
            this.linkStepSize.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkStepSize.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkStepSize.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkCatchFreq
            // 
            this.linkCatchFreq.Location = new System.Drawing.Point(296, 79);
            this.linkCatchFreq.Name = "linkCatchFreq";
            this.linkCatchFreq.Size = new System.Drawing.Size(128, 23);
            this.linkCatchFreq.TabIndex = 83;
            this.linkCatchFreq.TabStop = true;
            this.linkCatchFreq.Text = "Catch Trial Frequency:";
            this.linkCatchFreq.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkCatchFreq.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkCatchFreq.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkCatchLength
            // 
            this.linkCatchLength.Location = new System.Drawing.Point(296, 55);
            this.linkCatchLength.Name = "linkCatchLength";
            this.linkCatchLength.Size = new System.Drawing.Size(128, 23);
            this.linkCatchLength.TabIndex = 82;
            this.linkCatchLength.TabStop = true;
            this.linkCatchLength.Text = "Catch Trial Length (ms):";
            this.linkCatchLength.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkCatchLength.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkCatchLength.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkCatchTrials
            // 
            this.linkCatchTrials.Location = new System.Drawing.Point(296, 7);
            this.linkCatchTrials.Name = "linkCatchTrials";
            this.linkCatchTrials.Size = new System.Drawing.Size(128, 23);
            this.linkCatchTrials.TabIndex = 81;
            this.linkCatchTrials.TabStop = true;
            this.linkCatchTrials.Text = "Enable Catch Trials:";
            this.linkCatchTrials.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkCatchTrials.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkCatchTrials.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkCue
            // 
            this.linkCue.Location = new System.Drawing.Point(8, 296);
            this.linkCue.Name = "linkCue";
            this.linkCue.Size = new System.Drawing.Size(128, 23);
            this.linkCue.TabIndex = 80;
            this.linkCue.TabStop = true;
            this.linkCue.Text = "Play Cue:";
            this.linkCue.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkCue.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkCue.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // LinkWaitForNext
            // 
            this.LinkWaitForNext.Location = new System.Drawing.Point(8, 272);
            this.LinkWaitForNext.Name = "LinkWaitForNext";
            this.LinkWaitForNext.Size = new System.Drawing.Size(128, 23);
            this.LinkWaitForNext.TabIndex = 79;
            this.LinkWaitForNext.TabStop = true;
            this.LinkWaitForNext.Text = "Wait for \'Next\' Button:";
            this.LinkWaitForNext.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.LinkWaitForNext.VisitedLinkColor = System.Drawing.Color.Red;
            this.LinkWaitForNext.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkJitter
            // 
            this.linkJitter.Location = new System.Drawing.Point(8, 248);
            this.linkJitter.Name = "linkJitter";
            this.linkJitter.Size = new System.Drawing.Size(128, 23);
            this.linkJitter.TabIndex = 78;
            this.linkJitter.TabStop = true;
            this.linkJitter.Text = "ISI Jitter (ms):";
            this.linkJitter.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkJitter.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkJitter.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkIsi
            // 
            this.linkIsi.Location = new System.Drawing.Point(8, 224);
            this.linkIsi.Name = "linkIsi";
            this.linkIsi.Size = new System.Drawing.Size(128, 23);
            this.linkIsi.TabIndex = 77;
            this.linkIsi.TabStop = true;
            this.linkIsi.Text = "ISI (ms):";
            this.linkIsi.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkIsi.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkIsi.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkTimer
            // 
            this.linkTimer.Location = new System.Drawing.Point(8, 200);
            this.linkTimer.Name = "linkTimer";
            this.linkTimer.Size = new System.Drawing.Size(128, 23);
            this.linkTimer.TabIndex = 76;
            this.linkTimer.TabStop = true;
            this.linkTimer.Text = "Response Timer (ms):";
            this.linkTimer.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkTimer.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkTimer.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkGameDelay
            // 
            this.linkGameDelay.Location = new System.Drawing.Point(8, 152);
            this.linkGameDelay.Name = "linkGameDelay";
            this.linkGameDelay.Size = new System.Drawing.Size(128, 23);
            this.linkGameDelay.TabIndex = 75;
            this.linkGameDelay.TabStop = true;
            this.linkGameDelay.Text = "Game Delay:";
            this.linkGameDelay.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkGameDelay.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkGameDelay.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkMaxTrials
            // 
            this.linkMaxTrials.Location = new System.Drawing.Point(8, 128);
            this.linkMaxTrials.Name = "linkMaxTrials";
            this.linkMaxTrials.Size = new System.Drawing.Size(128, 23);
            this.linkMaxTrials.TabIndex = 74;
            this.linkMaxTrials.TabStop = true;
            this.linkMaxTrials.Text = "Max Trials:";
            this.linkMaxTrials.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkMaxTrials.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkMaxTrials.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkMaxLevel
            // 
            this.linkMaxLevel.Location = new System.Drawing.Point(8, 104);
            this.linkMaxLevel.Name = "linkMaxLevel";
            this.linkMaxLevel.Size = new System.Drawing.Size(128, 23);
            this.linkMaxLevel.TabIndex = 73;
            this.linkMaxLevel.TabStop = true;
            this.linkMaxLevel.Text = "Max Level:";
            this.linkMaxLevel.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkMaxLevel.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkMaxLevel.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkSecondaryContinuous
            // 
            this.linkSecondaryContinuous.Location = new System.Drawing.Point(8, 55);
            this.linkSecondaryContinuous.Name = "linkSecondaryContinuous";
            this.linkSecondaryContinuous.Size = new System.Drawing.Size(128, 23);
            this.linkSecondaryContinuous.TabIndex = 72;
            this.linkSecondaryContinuous.TabStop = true;
            this.linkSecondaryContinuous.Text = "Secondary Continuous:";
            this.linkSecondaryContinuous.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkSecondaryContinuous.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkSecondaryContinuous.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkSecondaryOrder
            // 
            this.linkSecondaryOrder.Location = new System.Drawing.Point(8, 31);
            this.linkSecondaryOrder.Name = "linkSecondaryOrder";
            this.linkSecondaryOrder.Size = new System.Drawing.Size(128, 23);
            this.linkSecondaryOrder.TabIndex = 71;
            this.linkSecondaryOrder.TabStop = true;
            this.linkSecondaryOrder.Text = "Secondary Order:";
            this.linkSecondaryOrder.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkSecondaryOrder.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkSecondaryOrder.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkPrimaryOrder
            // 
            this.linkPrimaryOrder.Location = new System.Drawing.Point(8, 7);
            this.linkPrimaryOrder.Name = "linkPrimaryOrder";
            this.linkPrimaryOrder.Size = new System.Drawing.Size(128, 23);
            this.linkPrimaryOrder.TabIndex = 70;
            this.linkPrimaryOrder.TabStop = true;
            this.linkPrimaryOrder.Text = "Primary Order:";
            this.linkPrimaryOrder.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkPrimaryOrder.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkPrimaryOrder.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // PrimaryOrder
            // 
            this.PrimaryOrder.Items.AddRange(new object[] {
            "Fixed",
            "Random"});
            this.PrimaryOrder.Location = new System.Drawing.Point(136, 8);
            this.PrimaryOrder.Name = "PrimaryOrder";
            this.PrimaryOrder.Size = new System.Drawing.Size(100, 21);
            this.PrimaryOrder.TabIndex = 69;
            this.PrimaryOrder.Text = "Fixed";
            // 
            // Interval
            // 
            this.Interval.Items.AddRange(new object[] {
            "False",
            "True"});
            this.Interval.Location = new System.Drawing.Point(424, 176);
            this.Interval.Name = "Interval";
            this.Interval.Size = new System.Drawing.Size(100, 21);
            this.Interval.Sorted = true;
            this.Interval.TabIndex = 67;
            this.Interval.Text = "False";
            // 
            // CatchTrials
            // 
            this.CatchTrials.Items.AddRange(new object[] {
            "False",
            "True"});
            this.CatchTrials.Location = new System.Drawing.Point(424, 8);
            this.CatchTrials.Name = "CatchTrials";
            this.CatchTrials.Size = new System.Drawing.Size(100, 21);
            this.CatchTrials.Sorted = true;
            this.CatchTrials.TabIndex = 66;
            this.CatchTrials.Text = "False";
            // 
            // Cue
            // 
            this.Cue.Items.AddRange(new object[] {
            "False",
            "True"});
            this.Cue.Location = new System.Drawing.Point(136, 296);
            this.Cue.Name = "Cue";
            this.Cue.Size = new System.Drawing.Size(100, 21);
            this.Cue.Sorted = true;
            this.Cue.TabIndex = 65;
            this.Cue.Text = "False";
            // 
            // WaitForNext
            // 
            this.WaitForNext.Items.AddRange(new object[] {
            "False",
            "True"});
            this.WaitForNext.Location = new System.Drawing.Point(136, 272);
            this.WaitForNext.Name = "WaitForNext";
            this.WaitForNext.Size = new System.Drawing.Size(100, 21);
            this.WaitForNext.Sorted = true;
            this.WaitForNext.TabIndex = 64;
            this.WaitForNext.Text = "False";
            // 
            // SecondaryContinuous
            // 
            this.SecondaryContinuous.Items.AddRange(new object[] {
            "False",
            "True"});
            this.SecondaryContinuous.Location = new System.Drawing.Point(136, 56);
            this.SecondaryContinuous.Name = "SecondaryContinuous";
            this.SecondaryContinuous.Size = new System.Drawing.Size(100, 21);
            this.SecondaryContinuous.Sorted = true;
            this.SecondaryContinuous.TabIndex = 62;
            this.SecondaryContinuous.Text = "False";
            // 
            // SecondaryOrder
            // 
            this.SecondaryOrder.Items.AddRange(new object[] {
            "Block",
            "InOrder",
            "Random",
            "RandomTrial",
            "RandomInterval"});
            this.SecondaryOrder.Location = new System.Drawing.Point(136, 32);
            this.SecondaryOrder.Name = "SecondaryOrder";
            this.SecondaryOrder.Size = new System.Drawing.Size(100, 21);
            this.SecondaryOrder.TabIndex = 61;
            this.SecondaryOrder.Text = "Block";
            // 
            // IntervalSpace
            // 
            this.IntervalSpace.Location = new System.Drawing.Point(424, 224);
            this.IntervalSpace.Name = "IntervalSpace";
            this.IntervalSpace.Size = new System.Drawing.Size(96, 20);
            this.IntervalSpace.TabIndex = 53;
            this.IntervalSpace.Text = "0";
            // 
            // IntervalLength
            // 
            this.IntervalLength.Location = new System.Drawing.Point(424, 200);
            this.IntervalLength.Name = "IntervalLength";
            this.IntervalLength.Size = new System.Drawing.Size(96, 20);
            this.IntervalLength.TabIndex = 51;
            this.IntervalLength.Text = "0";
            // 
            // Reps
            // 
            this.Reps.Location = new System.Drawing.Point(424, 152);
            this.Reps.Name = "Reps";
            this.Reps.Size = new System.Drawing.Size(96, 20);
            this.Reps.TabIndex = 47;
            this.Reps.Text = "1";
            // 
            // Range
            // 
            this.Range.Location = new System.Drawing.Point(424, 128);
            this.Range.Name = "Range";
            this.Range.Size = new System.Drawing.Size(96, 20);
            this.Range.TabIndex = 45;
            this.Range.Text = "0";
            // 
            // StepSize
            // 
            this.StepSize.Location = new System.Drawing.Point(424, 104);
            this.StepSize.Name = "StepSize";
            this.StepSize.Size = new System.Drawing.Size(96, 20);
            this.StepSize.TabIndex = 43;
            this.StepSize.Text = "0";
            // 
            // CatchFreq
            // 
            this.CatchFreq.Location = new System.Drawing.Point(424, 80);
            this.CatchFreq.Name = "CatchFreq";
            this.CatchFreq.Size = new System.Drawing.Size(96, 20);
            this.CatchFreq.TabIndex = 41;
            this.CatchFreq.Text = "0";
            // 
            // CatchLength
            // 
            this.CatchLength.Location = new System.Drawing.Point(424, 56);
            this.CatchLength.Name = "CatchLength";
            this.CatchLength.Size = new System.Drawing.Size(96, 20);
            this.CatchLength.TabIndex = 39;
            this.CatchLength.Text = "0";
            // 
            // Jitter
            // 
            this.Jitter.Location = new System.Drawing.Point(136, 248);
            this.Jitter.Name = "Jitter";
            this.Jitter.Size = new System.Drawing.Size(100, 20);
            this.Jitter.TabIndex = 35;
            this.Jitter.Text = "250";
            // 
            // ISI
            // 
            this.ISI.Location = new System.Drawing.Point(136, 224);
            this.ISI.Name = "ISI";
            this.ISI.Size = new System.Drawing.Size(100, 20);
            this.ISI.TabIndex = 33;
            this.ISI.Text = "2000";
            // 
            // Timer
            // 
            this.Timer.Location = new System.Drawing.Point(136, 200);
            this.Timer.Name = "Timer";
            this.Timer.Size = new System.Drawing.Size(100, 20);
            this.Timer.TabIndex = 31;
            this.Timer.Text = "5000";
            // 
            // GameDelay
            // 
            this.GameDelay.Location = new System.Drawing.Point(136, 152);
            this.GameDelay.Name = "GameDelay";
            this.GameDelay.Size = new System.Drawing.Size(100, 20);
            this.GameDelay.TabIndex = 29;
            this.GameDelay.Text = "0";
            // 
            // MaxTrials
            // 
            this.MaxTrials.Location = new System.Drawing.Point(136, 128);
            this.MaxTrials.Name = "MaxTrials";
            this.MaxTrials.Size = new System.Drawing.Size(100, 20);
            this.MaxTrials.TabIndex = 27;
            this.MaxTrials.Text = "NA";
            // 
            // MaxLevel
            // 
            this.MaxLevel.Location = new System.Drawing.Point(136, 104);
            this.MaxLevel.Name = "MaxLevel";
            this.MaxLevel.Size = new System.Drawing.Size(100, 20);
            this.MaxLevel.TabIndex = 25;
            this.MaxLevel.Text = "100";
            // 
            // tabCL
            // 
            this.tabCL.Controls.Add(this.linkLabel9);
            this.tabCL.Controls.Add(this.cmbUseAdaptive);
            this.tabCL.Controls.Add(this.linkLabel8);
            this.tabCL.Controls.Add(this.cmbButtonLayout);
            this.tabCL.Controls.Add(this.linkLabel6);
            this.tabCL.Controls.Add(this.CLReps);
            this.tabCL.Controls.Add(this.linkLabel7);
            this.tabCL.Controls.Add(this.CLAnchored);
            this.tabCL.Controls.Add(this.linkLabel5);
            this.tabCL.Controls.Add(this.CLButtons);
            this.tabCL.Controls.Add(this.linkLabel1);
            this.tabCL.Controls.Add(this.linkLabel2);
            this.tabCL.Controls.Add(this.linkLabel3);
            this.tabCL.Controls.Add(this.linkLabel4);
            this.tabCL.Controls.Add(this.CLPrimaryOrder);
            this.tabCL.Controls.Add(this.CLIsiJitter);
            this.tabCL.Controls.Add(this.CLIsi);
            this.tabCL.Controls.Add(this.CLMaxLevel);
            this.tabCL.Controls.Add(this.chkCL);
            this.tabCL.Location = new System.Drawing.Point(4, 22);
            this.tabCL.Name = "tabCL";
            this.tabCL.Size = new System.Drawing.Size(576, 390);
            this.tabCL.TabIndex = 7;
            this.tabCL.Text = "CL";
            // 
            // linkLabel9
            // 
            this.linkLabel9.Location = new System.Drawing.Point(8, 200);
            this.linkLabel9.Name = "linkLabel9";
            this.linkLabel9.Size = new System.Drawing.Size(128, 23);
            this.linkLabel9.TabIndex = 97;
            this.linkLabel9.TabStop = true;
            this.linkLabel9.Text = "Use Adaptive:";
            this.linkLabel9.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel9.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // cmbUseAdaptive
            // 
            this.cmbUseAdaptive.Items.AddRange(new object[] {
            "Yes",
            "No"});
            this.cmbUseAdaptive.Location = new System.Drawing.Point(136, 200);
            this.cmbUseAdaptive.Name = "cmbUseAdaptive";
            this.cmbUseAdaptive.Size = new System.Drawing.Size(100, 21);
            this.cmbUseAdaptive.TabIndex = 96;
            this.cmbUseAdaptive.Text = "Yes";
            // 
            // linkLabel8
            // 
            this.linkLabel8.Location = new System.Drawing.Point(8, 176);
            this.linkLabel8.Name = "linkLabel8";
            this.linkLabel8.Size = new System.Drawing.Size(128, 23);
            this.linkLabel8.TabIndex = 95;
            this.linkLabel8.TabStop = true;
            this.linkLabel8.Text = "Button Layout:";
            this.linkLabel8.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel8.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // cmbButtonLayout
            // 
            this.cmbButtonLayout.Items.AddRange(new object[] {
            "Default",
            "ISO Layout"});
            this.cmbButtonLayout.Location = new System.Drawing.Point(136, 176);
            this.cmbButtonLayout.Name = "cmbButtonLayout";
            this.cmbButtonLayout.Size = new System.Drawing.Size(100, 21);
            this.cmbButtonLayout.TabIndex = 94;
            this.cmbButtonLayout.Text = "Default";
            // 
            // linkLabel6
            // 
            this.linkLabel6.Location = new System.Drawing.Point(8, 56);
            this.linkLabel6.Name = "linkLabel6";
            this.linkLabel6.Size = new System.Drawing.Size(128, 23);
            this.linkLabel6.TabIndex = 93;
            this.linkLabel6.TabStop = true;
            this.linkLabel6.Text = "Repetitions:";
            this.linkLabel6.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel6.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // CLReps
            // 
            this.CLReps.Location = new System.Drawing.Point(136, 56);
            this.CLReps.Name = "CLReps";
            this.CLReps.Size = new System.Drawing.Size(100, 20);
            this.CLReps.TabIndex = 92;
            this.CLReps.Text = "100";
            // 
            // linkLabel7
            // 
            this.linkLabel7.Location = new System.Drawing.Point(8, 224);
            this.linkLabel7.Name = "linkLabel7";
            this.linkLabel7.Size = new System.Drawing.Size(128, 23);
            this.linkLabel7.TabIndex = 91;
            this.linkLabel7.TabStop = true;
            this.linkLabel7.Text = "Anchored Trials:";
            this.linkLabel7.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel7.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // CLAnchored
            // 
            this.CLAnchored.Items.AddRange(new object[] {
            "No",
            "Yes"});
            this.CLAnchored.Location = new System.Drawing.Point(136, 224);
            this.CLAnchored.Name = "CLAnchored";
            this.CLAnchored.Size = new System.Drawing.Size(100, 21);
            this.CLAnchored.TabIndex = 90;
            this.CLAnchored.Text = "No";
            // 
            // linkLabel5
            // 
            this.linkLabel5.Location = new System.Drawing.Point(8, 152);
            this.linkLabel5.Name = "linkLabel5";
            this.linkLabel5.Size = new System.Drawing.Size(128, 23);
            this.linkLabel5.TabIndex = 88;
            this.linkLabel5.TabStop = true;
            this.linkLabel5.Text = "Number of Buttons:";
            this.linkLabel5.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel5.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // CLButtons
            // 
            this.CLButtons.Location = new System.Drawing.Point(136, 152);
            this.CLButtons.Name = "CLButtons";
            this.CLButtons.Size = new System.Drawing.Size(100, 20);
            this.CLButtons.TabIndex = 87;
            this.CLButtons.Text = "11";
            // 
            // linkLabel1
            // 
            this.linkLabel1.Location = new System.Drawing.Point(8, 128);
            this.linkLabel1.Name = "linkLabel1";
            this.linkLabel1.Size = new System.Drawing.Size(128, 23);
            this.linkLabel1.TabIndex = 86;
            this.linkLabel1.TabStop = true;
            this.linkLabel1.Text = "ISI Jitter (ms):";
            this.linkLabel1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel1.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // linkLabel2
            // 
            this.linkLabel2.Location = new System.Drawing.Point(8, 104);
            this.linkLabel2.Name = "linkLabel2";
            this.linkLabel2.Size = new System.Drawing.Size(128, 23);
            this.linkLabel2.TabIndex = 85;
            this.linkLabel2.TabStop = true;
            this.linkLabel2.Text = "ISI (ms):";
            this.linkLabel2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel2.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // linkLabel3
            // 
            this.linkLabel3.Location = new System.Drawing.Point(8, 80);
            this.linkLabel3.Name = "linkLabel3";
            this.linkLabel3.Size = new System.Drawing.Size(128, 23);
            this.linkLabel3.TabIndex = 84;
            this.linkLabel3.TabStop = true;
            this.linkLabel3.Text = "Max Level:";
            this.linkLabel3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel3.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // linkLabel4
            // 
            this.linkLabel4.Location = new System.Drawing.Point(8, 32);
            this.linkLabel4.Name = "linkLabel4";
            this.linkLabel4.Size = new System.Drawing.Size(128, 23);
            this.linkLabel4.TabIndex = 83;
            this.linkLabel4.TabStop = true;
            this.linkLabel4.Text = "Primary Order:";
            this.linkLabel4.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkLabel4.VisitedLinkColor = System.Drawing.Color.Red;
            // 
            // CLPrimaryOrder
            // 
            this.CLPrimaryOrder.Items.AddRange(new object[] {
            "Fixed",
            "Random"});
            this.CLPrimaryOrder.Location = new System.Drawing.Point(136, 32);
            this.CLPrimaryOrder.Name = "CLPrimaryOrder";
            this.CLPrimaryOrder.Size = new System.Drawing.Size(100, 21);
            this.CLPrimaryOrder.TabIndex = 82;
            this.CLPrimaryOrder.Text = "Fixed";
            // 
            // CLIsiJitter
            // 
            this.CLIsiJitter.Location = new System.Drawing.Point(136, 128);
            this.CLIsiJitter.Name = "CLIsiJitter";
            this.CLIsiJitter.Size = new System.Drawing.Size(100, 20);
            this.CLIsiJitter.TabIndex = 81;
            this.CLIsiJitter.Text = "250";
            // 
            // CLIsi
            // 
            this.CLIsi.Location = new System.Drawing.Point(136, 104);
            this.CLIsi.Name = "CLIsi";
            this.CLIsi.Size = new System.Drawing.Size(100, 20);
            this.CLIsi.TabIndex = 80;
            this.CLIsi.Text = "2000";
            // 
            // CLMaxLevel
            // 
            this.CLMaxLevel.Location = new System.Drawing.Point(136, 80);
            this.CLMaxLevel.Name = "CLMaxLevel";
            this.CLMaxLevel.Size = new System.Drawing.Size(100, 20);
            this.CLMaxLevel.TabIndex = 79;
            this.CLMaxLevel.Text = "100";
            // 
            // chkCL
            // 
            this.chkCL.Location = new System.Drawing.Point(8, 8);
            this.chkCL.Name = "chkCL";
            this.chkCL.Size = new System.Drawing.Size(160, 24);
            this.chkCL.TabIndex = 0;
            this.chkCL.Text = "Run Categorical Loudness";
            this.chkCL.CheckedChanged += new System.EventHandler(this.chkCL_CheckedChanged);
            // 
            // tabPrimary
            // 
            this.tabPrimary.Controls.Add(this.pnlMode);
            this.tabPrimary.Controls.Add(this.tbAtteunate);
            this.tabPrimary.Controls.Add(this.PS10lbl);
            this.tabPrimary.Controls.Add(this.PS9lbl);
            this.tabPrimary.Controls.Add(this.btnPrimaryDown);
            this.tabPrimary.Controls.Add(this.btnPrimaryUp);
            this.tabPrimary.Controls.Add(this.linkPrimaryHelp);
            this.tabPrimary.Controls.Add(this.btnPSUpdate);
            this.tabPrimary.Controls.Add(this.btnPSBrowse);
            this.tabPrimary.Controls.Add(this.btnPSRemove);
            this.tabPrimary.Controls.Add(this.btnPSAdd);
            this.tabPrimary.Controls.Add(this.listPrimary);
            this.tabPrimary.Controls.Add(this.PS4lbl);
            this.tabPrimary.Controls.Add(this.PS3lbl);
            this.tabPrimary.Controls.Add(this.PS2lbl);
            this.tabPrimary.Controls.Add(this.PS1lbl);
            this.tabPrimary.Controls.Add(this.PS6txt);
            this.tabPrimary.Controls.Add(this.PS7txt);
            this.tabPrimary.Controls.Add(this.PS8txt);
            this.tabPrimary.Controls.Add(this.PS5txt);
            this.tabPrimary.Controls.Add(this.PS8lbl);
            this.tabPrimary.Controls.Add(this.PS7lbl);
            this.tabPrimary.Controls.Add(this.PS6lbl);
            this.tabPrimary.Controls.Add(this.PS5lbl);
            this.tabPrimary.Controls.Add(this.PS2txt);
            this.tabPrimary.Controls.Add(this.PS3txt);
            this.tabPrimary.Controls.Add(this.PS4txt);
            this.tabPrimary.Controls.Add(this.PS1txt);
            this.tabPrimary.Controls.Add(this.rdoPsWav);
            this.tabPrimary.Controls.Add(this.rdoPsPnbn);
            this.tabPrimary.Controls.Add(this.rdoPsNbn);
            this.tabPrimary.Controls.Add(this.rdoPsPulse);
            this.tabPrimary.Controls.Add(this.rdoPsTone);
            this.tabPrimary.Location = new System.Drawing.Point(4, 22);
            this.tabPrimary.Name = "tabPrimary";
            this.tabPrimary.Size = new System.Drawing.Size(609, 429);
            this.tabPrimary.TabIndex = 1;
            this.tabPrimary.Text = "Primary Stimuli";
            // 
            // btnPrimaryDown
            // 
            this.btnPrimaryDown.Image = ((System.Drawing.Image)(resources.GetObject("btnPrimaryDown.Image")));
            this.btnPrimaryDown.Location = new System.Drawing.Point(8, 306);
            this.btnPrimaryDown.Name = "btnPrimaryDown";
            this.btnPrimaryDown.Size = new System.Drawing.Size(24, 23);
            this.btnPrimaryDown.TabIndex = 53;
            this.btnPrimaryDown.Click += new System.EventHandler(this.btnPrimaryDown_Click);
            // 
            // btnPrimaryUp
            // 
            this.btnPrimaryUp.Image = ((System.Drawing.Image)(resources.GetObject("btnPrimaryUp.Image")));
            this.btnPrimaryUp.Location = new System.Drawing.Point(8, 258);
            this.btnPrimaryUp.Name = "btnPrimaryUp";
            this.btnPrimaryUp.Size = new System.Drawing.Size(24, 23);
            this.btnPrimaryUp.TabIndex = 52;
            this.btnPrimaryUp.Click += new System.EventHandler(this.btnPrimaryUp_Click);
            // 
            // linkPrimaryHelp
            // 
            this.linkPrimaryHelp.Location = new System.Drawing.Point(432, 8);
            this.linkPrimaryHelp.Name = "linkPrimaryHelp";
            this.linkPrimaryHelp.Size = new System.Drawing.Size(100, 23);
            this.linkPrimaryHelp.TabIndex = 51;
            this.linkPrimaryHelp.TabStop = true;
            this.linkPrimaryHelp.Text = "Help";
            this.linkPrimaryHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkPrimaryHelp.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // btnPSUpdate
            // 
            this.btnPSUpdate.Location = new System.Drawing.Point(259, 229);
            this.btnPSUpdate.Name = "btnPSUpdate";
            this.btnPSUpdate.Size = new System.Drawing.Size(75, 23);
            this.btnPSUpdate.TabIndex = 50;
            this.btnPSUpdate.Text = "Update";
            this.btnPSUpdate.Click += new System.EventHandler(this.btnPSUpdate_Click);
            // 
            // btnPSBrowse
            // 
            this.btnPSBrowse.Location = new System.Drawing.Point(456, 63);
            this.btnPSBrowse.Name = "btnPSBrowse";
            this.btnPSBrowse.Size = new System.Drawing.Size(75, 23);
            this.btnPSBrowse.TabIndex = 49;
            this.btnPSBrowse.Text = "Browse";
            this.btnPSBrowse.Click += new System.EventHandler(this.btnPSBrowse_Click);
            // 
            // btnPSRemove
            // 
            this.btnPSRemove.Location = new System.Drawing.Point(363, 229);
            this.btnPSRemove.Name = "btnPSRemove";
            this.btnPSRemove.Size = new System.Drawing.Size(75, 23);
            this.btnPSRemove.TabIndex = 16;
            this.btnPSRemove.Text = "Remove";
            this.btnPSRemove.Click += new System.EventHandler(this.btnPSRemove_Click);
            // 
            // btnPSAdd
            // 
            this.btnPSAdd.Location = new System.Drawing.Point(161, 229);
            this.btnPSAdd.Name = "btnPSAdd";
            this.btnPSAdd.Size = new System.Drawing.Size(75, 23);
            this.btnPSAdd.TabIndex = 15;
            this.btnPSAdd.Text = "Add";
            this.btnPSAdd.Click += new System.EventHandler(this.btnPSAdd_Click);
            // 
            // listPrimary
            // 
            this.listPrimary.Location = new System.Drawing.Point(38, 258);
            this.listPrimary.Name = "listPrimary";
            this.listPrimary.Size = new System.Drawing.Size(543, 168);
            this.listPrimary.TabIndex = 43;
            this.listPrimary.UseCompatibleStateImageBehavior = false;
            this.listPrimary.View = System.Windows.Forms.View.List;
            // 
            // PS4lbl
            // 
            this.PS4lbl.Location = new System.Drawing.Point(8, 136);
            this.PS4lbl.Name = "PS4lbl";
            this.PS4lbl.Size = new System.Drawing.Size(144, 23);
            this.PS4lbl.TabIndex = 42;
            this.PS4lbl.Text = "label13";
            this.PS4lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS3lbl
            // 
            this.PS3lbl.Location = new System.Drawing.Point(8, 112);
            this.PS3lbl.Name = "PS3lbl";
            this.PS3lbl.Size = new System.Drawing.Size(144, 23);
            this.PS3lbl.TabIndex = 41;
            this.PS3lbl.Text = "label14";
            this.PS3lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS2lbl
            // 
            this.PS2lbl.Location = new System.Drawing.Point(8, 88);
            this.PS2lbl.Name = "PS2lbl";
            this.PS2lbl.Size = new System.Drawing.Size(144, 23);
            this.PS2lbl.TabIndex = 40;
            this.PS2lbl.Text = "label15";
            this.PS2lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS1lbl
            // 
            this.PS1lbl.Location = new System.Drawing.Point(8, 64);
            this.PS1lbl.Name = "PS1lbl";
            this.PS1lbl.Size = new System.Drawing.Size(144, 23);
            this.PS1lbl.TabIndex = 39;
            this.PS1lbl.Text = "label16";
            this.PS1lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS6txt
            // 
            this.PS6txt.Location = new System.Drawing.Point(432, 88);
            this.PS6txt.Name = "PS6txt";
            this.PS6txt.Size = new System.Drawing.Size(100, 20);
            this.PS6txt.TabIndex = 11;
            // 
            // PS7txt
            // 
            this.PS7txt.Location = new System.Drawing.Point(432, 112);
            this.PS7txt.Name = "PS7txt";
            this.PS7txt.Size = new System.Drawing.Size(100, 20);
            this.PS7txt.TabIndex = 12;
            // 
            // PS8txt
            // 
            this.PS8txt.Location = new System.Drawing.Point(432, 136);
            this.PS8txt.Name = "PS8txt";
            this.PS8txt.Size = new System.Drawing.Size(100, 20);
            this.PS8txt.TabIndex = 13;
            // 
            // PS5txt
            // 
            this.PS5txt.Location = new System.Drawing.Point(432, 64);
            this.PS5txt.Name = "PS5txt";
            this.PS5txt.Size = new System.Drawing.Size(100, 20);
            this.PS5txt.TabIndex = 10;
            // 
            // PS8lbl
            // 
            this.PS8lbl.Location = new System.Drawing.Point(272, 136);
            this.PS8lbl.Name = "PS8lbl";
            this.PS8lbl.Size = new System.Drawing.Size(160, 23);
            this.PS8lbl.TabIndex = 34;
            this.PS8lbl.Text = "label9";
            this.PS8lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS7lbl
            // 
            this.PS7lbl.Location = new System.Drawing.Point(272, 112);
            this.PS7lbl.Name = "PS7lbl";
            this.PS7lbl.Size = new System.Drawing.Size(160, 23);
            this.PS7lbl.TabIndex = 33;
            this.PS7lbl.Text = "label10";
            this.PS7lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS6lbl
            // 
            this.PS6lbl.Location = new System.Drawing.Point(272, 88);
            this.PS6lbl.Name = "PS6lbl";
            this.PS6lbl.Size = new System.Drawing.Size(160, 23);
            this.PS6lbl.TabIndex = 32;
            this.PS6lbl.Text = "label11";
            this.PS6lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS5lbl
            // 
            this.PS5lbl.Location = new System.Drawing.Point(272, 64);
            this.PS5lbl.Name = "PS5lbl";
            this.PS5lbl.Size = new System.Drawing.Size(160, 23);
            this.PS5lbl.TabIndex = 31;
            this.PS5lbl.Text = "label12";
            this.PS5lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // PS2txt
            // 
            this.PS2txt.Location = new System.Drawing.Point(152, 88);
            this.PS2txt.Name = "PS2txt";
            this.PS2txt.Size = new System.Drawing.Size(100, 20);
            this.PS2txt.TabIndex = 7;
            // 
            // PS3txt
            // 
            this.PS3txt.Location = new System.Drawing.Point(152, 112);
            this.PS3txt.Name = "PS3txt";
            this.PS3txt.Size = new System.Drawing.Size(100, 20);
            this.PS3txt.TabIndex = 8;
            // 
            // PS4txt
            // 
            this.PS4txt.Location = new System.Drawing.Point(152, 136);
            this.PS4txt.Name = "PS4txt";
            this.PS4txt.Size = new System.Drawing.Size(100, 20);
            this.PS4txt.TabIndex = 9;
            // 
            // PS1txt
            // 
            this.PS1txt.Location = new System.Drawing.Point(152, 64);
            this.PS1txt.Name = "PS1txt";
            this.PS1txt.Size = new System.Drawing.Size(100, 20);
            this.PS1txt.TabIndex = 6;
            // 
            // rdoPsWav
            // 
            this.rdoPsWav.Location = new System.Drawing.Point(272, 8);
            this.rdoPsWav.Name = "rdoPsWav";
            this.rdoPsWav.Size = new System.Drawing.Size(84, 24);
            this.rdoPsWav.TabIndex = 3;
            this.rdoPsWav.Text = ".wav File";
            // 
            // rdoPsPnbn
            // 
            this.rdoPsPnbn.Location = new System.Drawing.Point(96, 32);
            this.rdoPsPnbn.Name = "rdoPsPnbn";
            this.rdoPsPnbn.Size = new System.Drawing.Size(160, 24);
            this.rdoPsPnbn.TabIndex = 5;
            this.rdoPsPnbn.Text = "Pulsed Narrow Band Noise";
            // 
            // rdoPsNbn
            // 
            this.rdoPsNbn.Location = new System.Drawing.Point(96, 8);
            this.rdoPsNbn.Name = "rdoPsNbn";
            this.rdoPsNbn.Size = new System.Drawing.Size(130, 24);
            this.rdoPsNbn.TabIndex = 2;
            this.rdoPsNbn.Text = "Narrow Band Noise";
            // 
            // rdoPsPulse
            // 
            this.rdoPsPulse.Location = new System.Drawing.Point(8, 32);
            this.rdoPsPulse.Name = "rdoPsPulse";
            this.rdoPsPulse.Size = new System.Drawing.Size(84, 24);
            this.rdoPsPulse.TabIndex = 4;
            this.rdoPsPulse.Text = "Pulse Tone";
            // 
            // rdoPsTone
            // 
            this.rdoPsTone.Location = new System.Drawing.Point(8, 8);
            this.rdoPsTone.Name = "rdoPsTone";
            this.rdoPsTone.Size = new System.Drawing.Size(56, 24);
            this.rdoPsTone.TabIndex = 1;
            this.rdoPsTone.Text = "Tone";
            // 
            // tabSecondary
            // 
            this.tabSecondary.Controls.Add(this.btnDownSecondary);
            this.tabSecondary.Controls.Add(this.btnUpSecondary);
            this.tabSecondary.Controls.Add(this.linkSecondaryHelp);
            this.tabSecondary.Controls.Add(this.btnSSUpdate);
            this.tabSecondary.Controls.Add(this.btnSSBrowse);
            this.tabSecondary.Controls.Add(this.btnSSRemove);
            this.tabSecondary.Controls.Add(this.btnSSAdd);
            this.tabSecondary.Controls.Add(this.listSecondary);
            this.tabSecondary.Controls.Add(this.SS6txt);
            this.tabSecondary.Controls.Add(this.SS7txt);
            this.tabSecondary.Controls.Add(this.SS8txt);
            this.tabSecondary.Controls.Add(this.SS5txt);
            this.tabSecondary.Controls.Add(this.SS8lbl);
            this.tabSecondary.Controls.Add(this.SS7lbl);
            this.tabSecondary.Controls.Add(this.SS6lbl);
            this.tabSecondary.Controls.Add(this.SS5lbl);
            this.tabSecondary.Controls.Add(this.SS2txt);
            this.tabSecondary.Controls.Add(this.SS3txt);
            this.tabSecondary.Controls.Add(this.SS4txt);
            this.tabSecondary.Controls.Add(this.SS1txt);
            this.tabSecondary.Controls.Add(this.SS4lbl);
            this.tabSecondary.Controls.Add(this.SS3lbl);
            this.tabSecondary.Controls.Add(this.SS2lbl);
            this.tabSecondary.Controls.Add(this.SS1lbl);
            this.tabSecondary.Controls.Add(this.rdoSsWav);
            this.tabSecondary.Controls.Add(this.rdoSsPnbn);
            this.tabSecondary.Controls.Add(this.rdoSsNbn);
            this.tabSecondary.Controls.Add(this.rdoSsPulse);
            this.tabSecondary.Controls.Add(this.rdoSsTone);
            this.tabSecondary.Location = new System.Drawing.Point(4, 22);
            this.tabSecondary.Name = "tabSecondary";
            this.tabSecondary.Size = new System.Drawing.Size(576, 390);
            this.tabSecondary.TabIndex = 2;
            this.tabSecondary.Text = "Secondary Stimuli";
            // 
            // btnDownSecondary
            // 
            this.btnDownSecondary.Image = ((System.Drawing.Image)(resources.GetObject("btnDownSecondary.Image")));
            this.btnDownSecondary.Location = new System.Drawing.Point(8, 248);
            this.btnDownSecondary.Name = "btnDownSecondary";
            this.btnDownSecondary.Size = new System.Drawing.Size(24, 23);
            this.btnDownSecondary.TabIndex = 55;
            this.btnDownSecondary.Click += new System.EventHandler(this.btnDownSecondary_Click);
            // 
            // btnUpSecondary
            // 
            this.btnUpSecondary.Image = ((System.Drawing.Image)(resources.GetObject("btnUpSecondary.Image")));
            this.btnUpSecondary.Location = new System.Drawing.Point(8, 200);
            this.btnUpSecondary.Name = "btnUpSecondary";
            this.btnUpSecondary.Size = new System.Drawing.Size(24, 23);
            this.btnUpSecondary.TabIndex = 54;
            this.btnUpSecondary.Click += new System.EventHandler(this.btnUpSecondary_Click);
            // 
            // linkSecondaryHelp
            // 
            this.linkSecondaryHelp.Location = new System.Drawing.Point(432, 8);
            this.linkSecondaryHelp.Name = "linkSecondaryHelp";
            this.linkSecondaryHelp.Size = new System.Drawing.Size(100, 23);
            this.linkSecondaryHelp.TabIndex = 52;
            this.linkSecondaryHelp.TabStop = true;
            this.linkSecondaryHelp.Text = "Help";
            this.linkSecondaryHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkSecondaryHelp.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // btnSSUpdate
            // 
            this.btnSSUpdate.Location = new System.Drawing.Point(235, 160);
            this.btnSSUpdate.Name = "btnSSUpdate";
            this.btnSSUpdate.Size = new System.Drawing.Size(75, 23);
            this.btnSSUpdate.TabIndex = 49;
            this.btnSSUpdate.Text = "Update";
            this.btnSSUpdate.Click += new System.EventHandler(this.btnSSUpdate_Click);
            // 
            // btnSSBrowse
            // 
            this.btnSSBrowse.Location = new System.Drawing.Point(456, 63);
            this.btnSSBrowse.Name = "btnSSBrowse";
            this.btnSSBrowse.Size = new System.Drawing.Size(75, 23);
            this.btnSSBrowse.TabIndex = 48;
            this.btnSSBrowse.Text = "Browse";
            this.btnSSBrowse.Click += new System.EventHandler(this.btnSSBrowse_Click);
            // 
            // btnSSRemove
            // 
            this.btnSSRemove.Location = new System.Drawing.Point(336, 160);
            this.btnSSRemove.Name = "btnSSRemove";
            this.btnSSRemove.Size = new System.Drawing.Size(75, 23);
            this.btnSSRemove.TabIndex = 47;
            this.btnSSRemove.Text = "Remove";
            this.btnSSRemove.Click += new System.EventHandler(this.btnSSRemove_Click);
            // 
            // btnSSAdd
            // 
            this.btnSSAdd.Location = new System.Drawing.Point(134, 160);
            this.btnSSAdd.Name = "btnSSAdd";
            this.btnSSAdd.Size = new System.Drawing.Size(75, 23);
            this.btnSSAdd.TabIndex = 46;
            this.btnSSAdd.Text = "Add";
            this.btnSSAdd.Click += new System.EventHandler(this.btnSSAdd_Click);
            // 
            // listSecondary
            // 
            this.listSecondary.Location = new System.Drawing.Point(48, 200);
            this.listSecondary.Name = "listSecondary";
            this.listSecondary.Size = new System.Drawing.Size(496, 184);
            this.listSecondary.TabIndex = 44;
            this.listSecondary.UseCompatibleStateImageBehavior = false;
            this.listSecondary.View = System.Windows.Forms.View.List;
            // 
            // SS6txt
            // 
            this.SS6txt.Location = new System.Drawing.Point(432, 88);
            this.SS6txt.Name = "SS6txt";
            this.SS6txt.Size = new System.Drawing.Size(100, 20);
            this.SS6txt.TabIndex = 26;
            // 
            // SS7txt
            // 
            this.SS7txt.Location = new System.Drawing.Point(432, 112);
            this.SS7txt.Name = "SS7txt";
            this.SS7txt.Size = new System.Drawing.Size(100, 20);
            this.SS7txt.TabIndex = 25;
            // 
            // SS8txt
            // 
            this.SS8txt.Location = new System.Drawing.Point(432, 136);
            this.SS8txt.Name = "SS8txt";
            this.SS8txt.Size = new System.Drawing.Size(100, 20);
            this.SS8txt.TabIndex = 24;
            // 
            // SS5txt
            // 
            this.SS5txt.Location = new System.Drawing.Point(432, 64);
            this.SS5txt.Name = "SS5txt";
            this.SS5txt.Size = new System.Drawing.Size(100, 20);
            this.SS5txt.TabIndex = 23;
            // 
            // SS8lbl
            // 
            this.SS8lbl.Location = new System.Drawing.Point(272, 136);
            this.SS8lbl.Name = "SS8lbl";
            this.SS8lbl.Size = new System.Drawing.Size(160, 23);
            this.SS8lbl.TabIndex = 22;
            this.SS8lbl.Text = "label5";
            this.SS8lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS7lbl
            // 
            this.SS7lbl.Location = new System.Drawing.Point(272, 112);
            this.SS7lbl.Name = "SS7lbl";
            this.SS7lbl.Size = new System.Drawing.Size(160, 23);
            this.SS7lbl.TabIndex = 21;
            this.SS7lbl.Text = "Amplitude:";
            this.SS7lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS6lbl
            // 
            this.SS6lbl.Location = new System.Drawing.Point(272, 88);
            this.SS6lbl.Name = "SS6lbl";
            this.SS6lbl.Size = new System.Drawing.Size(160, 23);
            this.SS6lbl.TabIndex = 20;
            this.SS6lbl.Text = "Ear:";
            this.SS6lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS5lbl
            // 
            this.SS5lbl.Location = new System.Drawing.Point(272, 64);
            this.SS5lbl.Name = "SS5lbl";
            this.SS5lbl.Size = new System.Drawing.Size(160, 23);
            this.SS5lbl.TabIndex = 19;
            this.SS5lbl.Text = "Ear:";
            this.SS5lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS2txt
            // 
            this.SS2txt.Location = new System.Drawing.Point(152, 88);
            this.SS2txt.Name = "SS2txt";
            this.SS2txt.Size = new System.Drawing.Size(100, 20);
            this.SS2txt.TabIndex = 18;
            // 
            // SS3txt
            // 
            this.SS3txt.Location = new System.Drawing.Point(152, 112);
            this.SS3txt.Name = "SS3txt";
            this.SS3txt.Size = new System.Drawing.Size(100, 20);
            this.SS3txt.TabIndex = 17;
            // 
            // SS4txt
            // 
            this.SS4txt.Location = new System.Drawing.Point(152, 136);
            this.SS4txt.Name = "SS4txt";
            this.SS4txt.Size = new System.Drawing.Size(100, 20);
            this.SS4txt.TabIndex = 16;
            // 
            // SS1txt
            // 
            this.SS1txt.Location = new System.Drawing.Point(152, 64);
            this.SS1txt.Name = "SS1txt";
            this.SS1txt.Size = new System.Drawing.Size(100, 20);
            this.SS1txt.TabIndex = 15;
            // 
            // SS4lbl
            // 
            this.SS4lbl.Location = new System.Drawing.Point(8, 136);
            this.SS4lbl.Name = "SS4lbl";
            this.SS4lbl.Size = new System.Drawing.Size(144, 23);
            this.SS4lbl.TabIndex = 14;
            this.SS4lbl.Text = "Level:";
            this.SS4lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS3lbl
            // 
            this.SS3lbl.Location = new System.Drawing.Point(8, 112);
            this.SS3lbl.Name = "SS3lbl";
            this.SS3lbl.Size = new System.Drawing.Size(144, 23);
            this.SS3lbl.TabIndex = 13;
            this.SS3lbl.Text = "Response:";
            this.SS3lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS2lbl
            // 
            this.SS2lbl.Location = new System.Drawing.Point(8, 88);
            this.SS2lbl.Name = "SS2lbl";
            this.SS2lbl.Size = new System.Drawing.Size(144, 23);
            this.SS2lbl.TabIndex = 12;
            this.SS2lbl.Text = "Category:";
            this.SS2lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // SS1lbl
            // 
            this.SS1lbl.Location = new System.Drawing.Point(8, 64);
            this.SS1lbl.Name = "SS1lbl";
            this.SS1lbl.Size = new System.Drawing.Size(144, 23);
            this.SS1lbl.TabIndex = 11;
            this.SS1lbl.Text = "File:";
            this.SS1lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // rdoSsWav
            // 
            this.rdoSsWav.Checked = true;
            this.rdoSsWav.Location = new System.Drawing.Point(272, 8);
            this.rdoSsWav.Name = "rdoSsWav";
            this.rdoSsWav.Size = new System.Drawing.Size(84, 24);
            this.rdoSsWav.TabIndex = 10;
            this.rdoSsWav.TabStop = true;
            this.rdoSsWav.Text = ".wav File";
            // 
            // rdoSsPnbn
            // 
            this.rdoSsPnbn.Location = new System.Drawing.Point(96, 32);
            this.rdoSsPnbn.Name = "rdoSsPnbn";
            this.rdoSsPnbn.Size = new System.Drawing.Size(160, 24);
            this.rdoSsPnbn.TabIndex = 9;
            this.rdoSsPnbn.Text = "Pulsed Narrow Band Noise";
            // 
            // rdoSsNbn
            // 
            this.rdoSsNbn.Location = new System.Drawing.Point(96, 8);
            this.rdoSsNbn.Name = "rdoSsNbn";
            this.rdoSsNbn.Size = new System.Drawing.Size(130, 24);
            this.rdoSsNbn.TabIndex = 8;
            this.rdoSsNbn.Text = "Narrow Band Noise";
            // 
            // rdoSsPulse
            // 
            this.rdoSsPulse.Location = new System.Drawing.Point(8, 32);
            this.rdoSsPulse.Name = "rdoSsPulse";
            this.rdoSsPulse.Size = new System.Drawing.Size(84, 24);
            this.rdoSsPulse.TabIndex = 7;
            this.rdoSsPulse.Text = "Pulse Tone";
            // 
            // rdoSsTone
            // 
            this.rdoSsTone.Location = new System.Drawing.Point(8, 8);
            this.rdoSsTone.Name = "rdoSsTone";
            this.rdoSsTone.Size = new System.Drawing.Size(56, 24);
            this.rdoSsTone.TabIndex = 6;
            this.rdoSsTone.Text = "Tone";
            // 
            // tabPaired
            // 
            this.tabPaired.Controls.Add(this.cbPlayLR);
            this.tabPaired.Controls.Add(this.label13);
            this.tabPaired.Controls.Add(this.cmbAmpType);
            this.tabPaired.Controls.Add(this.txtPaired4);
            this.tabPaired.Controls.Add(this.lblPaired4);
            this.tabPaired.Controls.Add(this.label12);
            this.tabPaired.Controls.Add(this.btnPairedUpdate);
            this.tabPaired.Controls.Add(this.btnPairedRemove);
            this.tabPaired.Controls.Add(this.btnPairedAdd);
            this.tabPaired.Controls.Add(this.txtPaired1);
            this.tabPaired.Controls.Add(this.txtPaired2);
            this.tabPaired.Controls.Add(this.txtPaired3);
            this.tabPaired.Controls.Add(this.lblPaired3);
            this.tabPaired.Controls.Add(this.lblPaired2);
            this.tabPaired.Controls.Add(this.lblPaired1);
            this.tabPaired.Controls.Add(this.listPaired);
            this.tabPaired.Controls.Add(this.btnPairedFolder);
            this.tabPaired.Controls.Add(this.txtPairedFolder);
            this.tabPaired.Controls.Add(this.lnkPairedHelp);
            this.tabPaired.Controls.Add(this.rbPairedWave);
            this.tabPaired.Location = new System.Drawing.Point(4, 22);
            this.tabPaired.Name = "tabPaired";
            this.tabPaired.Size = new System.Drawing.Size(576, 390);
            this.tabPaired.TabIndex = 9;
            this.tabPaired.Text = "Paired Stimuli";
            // 
            // cbPlayLR
            // 
            this.cbPlayLR.Location = new System.Drawing.Point(136, 16);
            this.cbPlayLR.Name = "cbPlayLR";
            this.cbPlayLR.Size = new System.Drawing.Size(136, 16);
            this.cbPlayLR.TabIndex = 103;
            this.cbPlayLR.Text = "Play 2 LR As Stereo";
            // 
            // label13
            // 
            this.label13.Location = new System.Drawing.Point(344, 96);
            this.label13.Name = "label13";
            this.label13.Size = new System.Drawing.Size(104, 24);
            this.label13.TabIndex = 102;
            this.label13.Text = "Amplification Type:";
            this.label13.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // cmbAmpType
            // 
            this.cmbAmpType.Items.AddRange(new object[] {
            "rms",
            "peak",
            "none"});
            this.cmbAmpType.Location = new System.Drawing.Point(448, 96);
            this.cmbAmpType.Name = "cmbAmpType";
            this.cmbAmpType.Size = new System.Drawing.Size(96, 21);
            this.cmbAmpType.TabIndex = 101;
            this.cmbAmpType.Text = "none";
            // 
            // txtPaired4
            // 
            this.txtPaired4.Location = new System.Drawing.Point(168, 168);
            this.txtPaired4.Name = "txtPaired4";
            this.txtPaired4.Size = new System.Drawing.Size(96, 20);
            this.txtPaired4.TabIndex = 80;
            // 
            // lblPaired4
            // 
            this.lblPaired4.Location = new System.Drawing.Point(32, 168);
            this.lblPaired4.Name = "lblPaired4";
            this.lblPaired4.Size = new System.Drawing.Size(136, 24);
            this.lblPaired4.TabIndex = 79;
            this.lblPaired4.Text = "Ear";
            this.lblPaired4.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // label12
            // 
            this.label12.Location = new System.Drawing.Point(120, 64);
            this.label12.Name = "label12";
            this.label12.Size = new System.Drawing.Size(40, 16);
            this.label12.TabIndex = 74;
            this.label12.Text = "Folder:";
            // 
            // btnPairedUpdate
            // 
            this.btnPairedUpdate.Location = new System.Drawing.Point(253, 200);
            this.btnPairedUpdate.Name = "btnPairedUpdate";
            this.btnPairedUpdate.Size = new System.Drawing.Size(75, 23);
            this.btnPairedUpdate.TabIndex = 62;
            this.btnPairedUpdate.Text = "Update";
            this.btnPairedUpdate.Click += new System.EventHandler(this.btnPairedUpdate_Click);
            // 
            // btnPairedRemove
            // 
            this.btnPairedRemove.Location = new System.Drawing.Point(354, 200);
            this.btnPairedRemove.Name = "btnPairedRemove";
            this.btnPairedRemove.Size = new System.Drawing.Size(75, 23);
            this.btnPairedRemove.TabIndex = 63;
            this.btnPairedRemove.Text = "Remove";
            this.btnPairedRemove.Click += new System.EventHandler(this.btnPairedRemove_Click);
            // 
            // btnPairedAdd
            // 
            this.btnPairedAdd.Location = new System.Drawing.Point(152, 200);
            this.btnPairedAdd.Name = "btnPairedAdd";
            this.btnPairedAdd.Size = new System.Drawing.Size(75, 23);
            this.btnPairedAdd.TabIndex = 61;
            this.btnPairedAdd.Text = "Add";
            this.btnPairedAdd.Click += new System.EventHandler(this.btnPairedAdd_Click);
            // 
            // txtPaired1
            // 
            this.txtPaired1.Location = new System.Drawing.Point(168, 96);
            this.txtPaired1.Name = "txtPaired1";
            this.txtPaired1.Size = new System.Drawing.Size(96, 20);
            this.txtPaired1.TabIndex = 56;
            // 
            // txtPaired2
            // 
            this.txtPaired2.Location = new System.Drawing.Point(168, 120);
            this.txtPaired2.Name = "txtPaired2";
            this.txtPaired2.Size = new System.Drawing.Size(96, 20);
            this.txtPaired2.TabIndex = 57;
            // 
            // txtPaired3
            // 
            this.txtPaired3.Location = new System.Drawing.Point(168, 144);
            this.txtPaired3.Name = "txtPaired3";
            this.txtPaired3.Size = new System.Drawing.Size(96, 20);
            this.txtPaired3.TabIndex = 58;
            // 
            // lblPaired3
            // 
            this.lblPaired3.Location = new System.Drawing.Point(24, 144);
            this.lblPaired3.Name = "lblPaired3";
            this.lblPaired3.Size = new System.Drawing.Size(144, 23);
            this.lblPaired3.TabIndex = 61;
            this.lblPaired3.Text = "Level:";
            this.lblPaired3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // lblPaired2
            // 
            this.lblPaired2.Location = new System.Drawing.Point(24, 120);
            this.lblPaired2.Name = "lblPaired2";
            this.lblPaired2.Size = new System.Drawing.Size(144, 23);
            this.lblPaired2.TabIndex = 60;
            this.lblPaired2.Text = "Response:";
            this.lblPaired2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // lblPaired1
            // 
            this.lblPaired1.Location = new System.Drawing.Point(24, 96);
            this.lblPaired1.Name = "lblPaired1";
            this.lblPaired1.Size = new System.Drawing.Size(144, 23);
            this.lblPaired1.TabIndex = 59;
            this.lblPaired1.Text = "Category:";
            this.lblPaired1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // listPaired
            // 
            this.listPaired.Location = new System.Drawing.Point(48, 232);
            this.listPaired.Name = "listPaired";
            this.listPaired.Size = new System.Drawing.Size(496, 168);
            this.listPaired.TabIndex = 64;
            this.listPaired.UseCompatibleStateImageBehavior = false;
            this.listPaired.View = System.Windows.Forms.View.List;
            this.listPaired.SelectedIndexChanged += new System.EventHandler(this.listPaired_SelectedIndexChanged);
            this.listPaired.Click += new System.EventHandler(this.listPaired_Click);
            // 
            // btnPairedFolder
            // 
            this.btnPairedFolder.Location = new System.Drawing.Point(472, 64);
            this.btnPairedFolder.Name = "btnPairedFolder";
            this.btnPairedFolder.Size = new System.Drawing.Size(56, 24);
            this.btnPairedFolder.TabIndex = 55;
            this.btnPairedFolder.Text = "Browse";
            this.btnPairedFolder.Click += new System.EventHandler(this.btnPairedFolder_Click);
            // 
            // txtPairedFolder
            // 
            this.txtPairedFolder.Location = new System.Drawing.Point(168, 64);
            this.txtPairedFolder.Name = "txtPairedFolder";
            this.txtPairedFolder.Size = new System.Drawing.Size(300, 20);
            this.txtPairedFolder.TabIndex = 54;
            // 
            // lnkPairedHelp
            // 
            this.lnkPairedHelp.Location = new System.Drawing.Point(432, 8);
            this.lnkPairedHelp.Name = "lnkPairedHelp";
            this.lnkPairedHelp.Size = new System.Drawing.Size(100, 23);
            this.lnkPairedHelp.TabIndex = 53;
            this.lnkPairedHelp.TabStop = true;
            this.lnkPairedHelp.Text = "Help";
            this.lnkPairedHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // rbPairedWave
            // 
            this.rbPairedWave.Checked = true;
            this.rbPairedWave.Location = new System.Drawing.Point(24, 16);
            this.rbPairedWave.Name = "rbPairedWave";
            this.rbPairedWave.Size = new System.Drawing.Size(84, 24);
            this.rbPairedWave.TabIndex = 53;
            this.rbPairedWave.TabStop = true;
            this.rbPairedWave.Text = ".wav File";
            this.rbPairedWave.Click += new System.EventHandler(this.DisplayPairedControls);
            // 
            // tabAdaptive
            // 
            this.tabAdaptive.Controls.Add(this.linkReversalsStop);
            this.tabAdaptive.Controls.Add(this.linkReversals);
            this.tabAdaptive.Controls.Add(this.linkStandardError);
            this.tabAdaptive.Controls.Add(this.linkStopMode);
            this.tabAdaptive.Controls.Add(this.linkSecondaryStepSize);
            this.tabAdaptive.Controls.Add(this.linkPrimaryStepSize);
            this.tabAdaptive.Controls.Add(this.linkOnCorrect);
            this.tabAdaptive.Controls.Add(this.linkMethod);
            this.tabAdaptive.Controls.Add(this.linkAdaptive);
            this.tabAdaptive.Controls.Add(this.StopMode);
            this.tabAdaptive.Controls.Add(this.OnCorrect);
            this.tabAdaptive.Controls.Add(this.NumOfStopReversals);
            this.tabAdaptive.Controls.Add(this.NumOfReversals);
            this.tabAdaptive.Controls.Add(this.StandardError);
            this.tabAdaptive.Controls.Add(this.SecondaryStep);
            this.tabAdaptive.Controls.Add(this.PrimaryStep);
            this.tabAdaptive.Controls.Add(this.Method);
            this.tabAdaptive.Controls.Add(this.Adaptive);
            this.tabAdaptive.Location = new System.Drawing.Point(4, 22);
            this.tabAdaptive.Name = "tabAdaptive";
            this.tabAdaptive.Size = new System.Drawing.Size(576, 390);
            this.tabAdaptive.TabIndex = 5;
            this.tabAdaptive.Text = "Adaptive";
            // 
            // linkReversalsStop
            // 
            this.linkReversalsStop.Location = new System.Drawing.Point(0, 199);
            this.linkReversalsStop.Name = "linkReversalsStop";
            this.linkReversalsStop.Size = new System.Drawing.Size(200, 23);
            this.linkReversalsStop.TabIndex = 86;
            this.linkReversalsStop.TabStop = true;
            this.linkReversalsStop.Text = "# of Reversals to Stop:";
            this.linkReversalsStop.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkReversalsStop.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkReversalsStop.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkReversals
            // 
            this.linkReversals.Location = new System.Drawing.Point(0, 175);
            this.linkReversals.Name = "linkReversals";
            this.linkReversals.Size = new System.Drawing.Size(200, 23);
            this.linkReversals.TabIndex = 85;
            this.linkReversals.TabStop = true;
            this.linkReversals.Text = "# of Reversals, Primary to Secondary:";
            this.linkReversals.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkReversals.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkReversals.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkStandardError
            // 
            this.linkStandardError.Location = new System.Drawing.Point(0, 151);
            this.linkStandardError.Name = "linkStandardError";
            this.linkStandardError.Size = new System.Drawing.Size(200, 23);
            this.linkStandardError.TabIndex = 84;
            this.linkStandardError.TabStop = true;
            this.linkStandardError.Text = "Standard Error:";
            this.linkStandardError.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkStandardError.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkStandardError.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkStopMode
            // 
            this.linkStopMode.Location = new System.Drawing.Point(0, 127);
            this.linkStopMode.Name = "linkStopMode";
            this.linkStopMode.Size = new System.Drawing.Size(200, 23);
            this.linkStopMode.TabIndex = 83;
            this.linkStopMode.TabStop = true;
            this.linkStopMode.Text = "Stop Mode:";
            this.linkStopMode.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkStopMode.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkStopMode.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkSecondaryStepSize
            // 
            this.linkSecondaryStepSize.Location = new System.Drawing.Point(0, 103);
            this.linkSecondaryStepSize.Name = "linkSecondaryStepSize";
            this.linkSecondaryStepSize.Size = new System.Drawing.Size(200, 23);
            this.linkSecondaryStepSize.TabIndex = 82;
            this.linkSecondaryStepSize.TabStop = true;
            this.linkSecondaryStepSize.Text = "Final Step Size:";
            this.linkSecondaryStepSize.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkSecondaryStepSize.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkSecondaryStepSize.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkPrimaryStepSize
            // 
            this.linkPrimaryStepSize.Location = new System.Drawing.Point(0, 79);
            this.linkPrimaryStepSize.Name = "linkPrimaryStepSize";
            this.linkPrimaryStepSize.Size = new System.Drawing.Size(200, 23);
            this.linkPrimaryStepSize.TabIndex = 81;
            this.linkPrimaryStepSize.TabStop = true;
            this.linkPrimaryStepSize.Text = "Initial Step Size:";
            this.linkPrimaryStepSize.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkPrimaryStepSize.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkPrimaryStepSize.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkOnCorrect
            // 
            this.linkOnCorrect.Location = new System.Drawing.Point(0, 55);
            this.linkOnCorrect.Name = "linkOnCorrect";
            this.linkOnCorrect.Size = new System.Drawing.Size(200, 23);
            this.linkOnCorrect.TabIndex = 80;
            this.linkOnCorrect.TabStop = true;
            this.linkOnCorrect.Text = "On Correct Response:";
            this.linkOnCorrect.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkOnCorrect.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkOnCorrect.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkMethod
            // 
            this.linkMethod.Location = new System.Drawing.Point(0, 31);
            this.linkMethod.Name = "linkMethod";
            this.linkMethod.Size = new System.Drawing.Size(200, 23);
            this.linkMethod.TabIndex = 79;
            this.linkMethod.TabStop = true;
            this.linkMethod.Text = "Method:";
            this.linkMethod.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkMethod.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkMethod.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // linkAdaptive
            // 
            this.linkAdaptive.Location = new System.Drawing.Point(0, 7);
            this.linkAdaptive.Name = "linkAdaptive";
            this.linkAdaptive.Size = new System.Drawing.Size(200, 23);
            this.linkAdaptive.TabIndex = 78;
            this.linkAdaptive.TabStop = true;
            this.linkAdaptive.Text = "Adaptive:";
            this.linkAdaptive.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkAdaptive.VisitedLinkColor = System.Drawing.Color.Red;
            this.linkAdaptive.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // StopMode
            // 
            this.StopMode.Items.AddRange(new object[] {
            "StdErr",
            "Reversals",
            "Both"});
            this.StopMode.Location = new System.Drawing.Point(200, 128);
            this.StopMode.Name = "StopMode";
            this.StopMode.Size = new System.Drawing.Size(100, 21);
            this.StopMode.TabIndex = 77;
            this.StopMode.Text = "StdErr";
            // 
            // OnCorrect
            // 
            this.OnCorrect.Items.AddRange(new object[] {
            "Decrease Level",
            "Increase Level"});
            this.OnCorrect.Location = new System.Drawing.Point(200, 56);
            this.OnCorrect.Name = "OnCorrect";
            this.OnCorrect.Size = new System.Drawing.Size(100, 21);
            this.OnCorrect.TabIndex = 76;
            this.OnCorrect.Text = "Decrease Level";
            // 
            // NumOfStopReversals
            // 
            this.NumOfStopReversals.Location = new System.Drawing.Point(200, 200);
            this.NumOfStopReversals.Name = "NumOfStopReversals";
            this.NumOfStopReversals.Size = new System.Drawing.Size(100, 20);
            this.NumOfStopReversals.TabIndex = 75;
            this.NumOfStopReversals.Text = "4";
            // 
            // NumOfReversals
            // 
            this.NumOfReversals.Location = new System.Drawing.Point(200, 176);
            this.NumOfReversals.Name = "NumOfReversals";
            this.NumOfReversals.Size = new System.Drawing.Size(100, 20);
            this.NumOfReversals.TabIndex = 73;
            this.NumOfReversals.Text = "2";
            // 
            // StandardError
            // 
            this.StandardError.Location = new System.Drawing.Point(200, 152);
            this.StandardError.Name = "StandardError";
            this.StandardError.Size = new System.Drawing.Size(100, 20);
            this.StandardError.TabIndex = 71;
            this.StandardError.Text = "2.5";
            // 
            // SecondaryStep
            // 
            this.SecondaryStep.Location = new System.Drawing.Point(200, 104);
            this.SecondaryStep.Name = "SecondaryStep";
            this.SecondaryStep.Size = new System.Drawing.Size(100, 20);
            this.SecondaryStep.TabIndex = 68;
            this.SecondaryStep.Text = "5";
            // 
            // PrimaryStep
            // 
            this.PrimaryStep.Location = new System.Drawing.Point(200, 80);
            this.PrimaryStep.Name = "PrimaryStep";
            this.PrimaryStep.Size = new System.Drawing.Size(100, 20);
            this.PrimaryStep.TabIndex = 66;
            this.PrimaryStep.Text = "10";
            // 
            // Method
            // 
            this.Method.Items.AddRange(new object[] {
            "50",
            "70",
            "30"});
            this.Method.Location = new System.Drawing.Point(200, 32);
            this.Method.Name = "Method";
            this.Method.Size = new System.Drawing.Size(100, 21);
            this.Method.TabIndex = 62;
            this.Method.Text = "50";
            // 
            // Adaptive
            // 
            this.Adaptive.Items.AddRange(new object[] {
            "None",
            "Primary",
            "Secondary",
            "Across Primary"});
            this.Adaptive.Location = new System.Drawing.Point(200, 8);
            this.Adaptive.Name = "Adaptive";
            this.Adaptive.Size = new System.Drawing.Size(100, 21);
            this.Adaptive.TabIndex = 61;
            this.Adaptive.Text = "None";
            // 
            // tabResults
            // 
            this.tabResults.Controls.Add(this.linkResultsHelp);
            this.tabResults.Controls.Add(this.txtResults);
            this.tabResults.Controls.Add(this.ResAltCat);
            this.tabResults.Controls.Add(this.ResStimCat);
            this.tabResults.Controls.Add(this.ResSecondary);
            this.tabResults.Controls.Add(this.ResPrimary);
            this.tabResults.Controls.Add(this.ResMethod);
            this.tabResults.Controls.Add(this.ResEar);
            this.tabResults.Controls.Add(this.groupBox1);
            this.tabResults.Location = new System.Drawing.Point(4, 22);
            this.tabResults.Name = "tabResults";
            this.tabResults.Size = new System.Drawing.Size(576, 390);
            this.tabResults.TabIndex = 4;
            this.tabResults.Text = "Results";
            // 
            // linkResultsHelp
            // 
            this.linkResultsHelp.Location = new System.Drawing.Point(432, 8);
            this.linkResultsHelp.Name = "linkResultsHelp";
            this.linkResultsHelp.Size = new System.Drawing.Size(100, 23);
            this.linkResultsHelp.TabIndex = 52;
            this.linkResultsHelp.TabStop = true;
            this.linkResultsHelp.Text = "Help";
            this.linkResultsHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkResultsHelp.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // txtResults
            // 
            this.txtResults.Location = new System.Drawing.Point(8, 280);
            this.txtResults.Name = "txtResults";
            this.txtResults.Size = new System.Drawing.Size(208, 20);
            this.txtResults.TabIndex = 7;
            // 
            // ResAltCat
            // 
            this.ResAltCat.Location = new System.Drawing.Point(8, 247);
            this.ResAltCat.Name = "ResAltCat";
            this.ResAltCat.Size = new System.Drawing.Size(208, 24);
            this.ResAltCat.TabIndex = 6;
            this.ResAltCat.Text = "Alternate Category";
            // 
            // ResStimCat
            // 
            this.ResStimCat.Location = new System.Drawing.Point(8, 220);
            this.ResStimCat.Name = "ResStimCat";
            this.ResStimCat.Size = new System.Drawing.Size(208, 24);
            this.ResStimCat.TabIndex = 5;
            this.ResStimCat.Text = "Response Category";
            // 
            // ResSecondary
            // 
            this.ResSecondary.Location = new System.Drawing.Point(8, 193);
            this.ResSecondary.Name = "ResSecondary";
            this.ResSecondary.Size = new System.Drawing.Size(208, 24);
            this.ResSecondary.TabIndex = 4;
            this.ResSecondary.Text = "Secondary Stimulus";
            // 
            // ResPrimary
            // 
            this.ResPrimary.Location = new System.Drawing.Point(8, 166);
            this.ResPrimary.Name = "ResPrimary";
            this.ResPrimary.Size = new System.Drawing.Size(208, 24);
            this.ResPrimary.TabIndex = 3;
            this.ResPrimary.Text = "Primary Stimulus";
            // 
            // ResMethod
            // 
            this.ResMethod.Location = new System.Drawing.Point(8, 139);
            this.ResMethod.Name = "ResMethod";
            this.ResMethod.Size = new System.Drawing.Size(208, 24);
            this.ResMethod.TabIndex = 2;
            this.ResMethod.Text = "Method";
            // 
            // ResEar
            // 
            this.ResEar.Location = new System.Drawing.Point(8, 112);
            this.ResEar.Name = "ResEar";
            this.ResEar.Size = new System.Drawing.Size(208, 24);
            this.ResEar.TabIndex = 1;
            this.ResEar.Text = "Ear";
            // 
            // groupBox1
            // 
            this.groupBox1.Controls.Add(this.ResFreq);
            this.groupBox1.Controls.Add(this.ResPerf);
            this.groupBox1.Location = new System.Drawing.Point(8, 16);
            this.groupBox1.Name = "groupBox1";
            this.groupBox1.Size = new System.Drawing.Size(200, 80);
            this.groupBox1.TabIndex = 0;
            this.groupBox1.TabStop = false;
            this.groupBox1.Text = "Fixed";
            // 
            // ResFreq
            // 
            this.ResFreq.Location = new System.Drawing.Point(16, 48);
            this.ResFreq.Name = "ResFreq";
            this.ResFreq.Size = new System.Drawing.Size(104, 24);
            this.ResFreq.TabIndex = 1;
            this.ResFreq.Text = "Frequency";
            // 
            // ResPerf
            // 
            this.ResPerf.Location = new System.Drawing.Point(16, 24);
            this.ResPerf.Name = "ResPerf";
            this.ResPerf.Size = new System.Drawing.Size(104, 24);
            this.ResPerf.TabIndex = 0;
            this.ResPerf.Text = "Performance";
            // 
            // tabFeedback
            // 
            this.tabFeedback.Controls.Add(this.groupBox2);
            this.tabFeedback.Controls.Add(this.btnDownFeedback);
            this.tabFeedback.Controls.Add(this.btnUpFeedback);
            this.tabFeedback.Controls.Add(this.linkFeedbackHelp);
            this.tabFeedback.Controls.Add(this.listFeedback);
            this.tabFeedback.Controls.Add(this.btnFeedbackRemove);
            this.tabFeedback.Controls.Add(this.btnFeedbackAdd);
            this.tabFeedback.Controls.Add(this.label9);
            this.tabFeedback.Location = new System.Drawing.Point(4, 22);
            this.tabFeedback.Name = "tabFeedback";
            this.tabFeedback.Size = new System.Drawing.Size(576, 390);
            this.tabFeedback.TabIndex = 3;
            this.tabFeedback.Text = "Feedback";
            // 
            // groupBox2
            // 
            this.groupBox2.Controls.Add(this.txtFeedHgt);
            this.groupBox2.Controls.Add(this.label18);
            this.groupBox2.Controls.Add(this.txtFeedWid);
            this.groupBox2.Controls.Add(this.label17);
            this.groupBox2.Controls.Add(this.txtFeedY);
            this.groupBox2.Controls.Add(this.txtFeedX);
            this.groupBox2.Controls.Add(this.label16);
            this.groupBox2.Controls.Add(this.label15);
            this.groupBox2.Location = new System.Drawing.Point(272, 8);
            this.groupBox2.Name = "groupBox2";
            this.groupBox2.Size = new System.Drawing.Size(272, 80);
            this.groupBox2.TabIndex = 56;
            this.groupBox2.TabStop = false;
            this.groupBox2.Text = "Feedback Dimensions";
            // 
            // txtFeedHgt
            // 
            this.txtFeedHgt.Location = new System.Drawing.Point(208, 48);
            this.txtFeedHgt.Name = "txtFeedHgt";
            this.txtFeedHgt.Size = new System.Drawing.Size(56, 20);
            this.txtFeedHgt.TabIndex = 7;
            this.txtFeedHgt.TextChanged += new System.EventHandler(this.textBox4_TextChanged);
            this.txtFeedHgt.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txtFeedY_KeyPress);
            // 
            // label18
            // 
            this.label18.Location = new System.Drawing.Point(160, 48);
            this.label18.Name = "label18";
            this.label18.Size = new System.Drawing.Size(40, 16);
            this.label18.TabIndex = 6;
            this.label18.Text = "Height:";
            // 
            // txtFeedWid
            // 
            this.txtFeedWid.Location = new System.Drawing.Point(208, 24);
            this.txtFeedWid.Name = "txtFeedWid";
            this.txtFeedWid.Size = new System.Drawing.Size(56, 20);
            this.txtFeedWid.TabIndex = 5;
            this.txtFeedWid.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txtFeedY_KeyPress);
            // 
            // label17
            // 
            this.label17.Location = new System.Drawing.Point(160, 24);
            this.label17.Name = "label17";
            this.label17.Size = new System.Drawing.Size(56, 16);
            this.label17.TabIndex = 4;
            this.label17.Text = "Width:";
            // 
            // txtFeedY
            // 
            this.txtFeedY.Location = new System.Drawing.Point(80, 48);
            this.txtFeedY.Name = "txtFeedY";
            this.txtFeedY.Size = new System.Drawing.Size(56, 20);
            this.txtFeedY.TabIndex = 3;
            this.txtFeedY.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txtFeedY_KeyPress);
            // 
            // txtFeedX
            // 
            this.txtFeedX.Location = new System.Drawing.Point(80, 24);
            this.txtFeedX.Name = "txtFeedX";
            this.txtFeedX.Size = new System.Drawing.Size(56, 20);
            this.txtFeedX.TabIndex = 2;
            this.txtFeedX.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txtFeedY_KeyPress);
            // 
            // label16
            // 
            this.label16.Location = new System.Drawing.Point(8, 48);
            this.label16.Name = "label16";
            this.label16.Size = new System.Drawing.Size(64, 16);
            this.label16.TabIndex = 1;
            this.label16.Text = "Top-Left-Y :";
            // 
            // label15
            // 
            this.label15.Location = new System.Drawing.Point(8, 24);
            this.label15.Name = "label15";
            this.label15.Size = new System.Drawing.Size(72, 16);
            this.label15.TabIndex = 0;
            this.label15.Text = "Top-Left-X:";
            // 
            // btnDownFeedback
            // 
            this.btnDownFeedback.Image = ((System.Drawing.Image)(resources.GetObject("btnDownFeedback.Image")));
            this.btnDownFeedback.Location = new System.Drawing.Point(8, 248);
            this.btnDownFeedback.Name = "btnDownFeedback";
            this.btnDownFeedback.Size = new System.Drawing.Size(24, 23);
            this.btnDownFeedback.TabIndex = 55;
            this.btnDownFeedback.Click += new System.EventHandler(this.btnDownFeedback_Click);
            // 
            // btnUpFeedback
            // 
            this.btnUpFeedback.Image = ((System.Drawing.Image)(resources.GetObject("btnUpFeedback.Image")));
            this.btnUpFeedback.Location = new System.Drawing.Point(8, 200);
            this.btnUpFeedback.Name = "btnUpFeedback";
            this.btnUpFeedback.Size = new System.Drawing.Size(24, 23);
            this.btnUpFeedback.TabIndex = 54;
            this.btnUpFeedback.Click += new System.EventHandler(this.btnUpFeedback_Click);
            // 
            // linkFeedbackHelp
            // 
            this.linkFeedbackHelp.Location = new System.Drawing.Point(528, 8);
            this.linkFeedbackHelp.Name = "linkFeedbackHelp";
            this.linkFeedbackHelp.Size = new System.Drawing.Size(40, 23);
            this.linkFeedbackHelp.TabIndex = 52;
            this.linkFeedbackHelp.TabStop = true;
            this.linkFeedbackHelp.Text = "Help";
            this.linkFeedbackHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkFeedbackHelp.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // listFeedback
            // 
            this.listFeedback.Location = new System.Drawing.Point(48, 88);
            this.listFeedback.Name = "listFeedback";
            this.listFeedback.Size = new System.Drawing.Size(496, 296);
            this.listFeedback.TabIndex = 3;
            this.listFeedback.UseCompatibleStateImageBehavior = false;
            this.listFeedback.View = System.Windows.Forms.View.List;
            // 
            // btnFeedbackRemove
            // 
            this.btnFeedbackRemove.Location = new System.Drawing.Point(128, 32);
            this.btnFeedbackRemove.Name = "btnFeedbackRemove";
            this.btnFeedbackRemove.Size = new System.Drawing.Size(75, 23);
            this.btnFeedbackRemove.TabIndex = 2;
            this.btnFeedbackRemove.Text = "Remove";
            this.btnFeedbackRemove.Click += new System.EventHandler(this.btnFeedbackRemove_Click);
            // 
            // btnFeedbackAdd
            // 
            this.btnFeedbackAdd.Location = new System.Drawing.Point(8, 32);
            this.btnFeedbackAdd.Name = "btnFeedbackAdd";
            this.btnFeedbackAdd.Size = new System.Drawing.Size(75, 23);
            this.btnFeedbackAdd.TabIndex = 1;
            this.btnFeedbackAdd.Text = "Add";
            this.btnFeedbackAdd.Click += new System.EventHandler(this.btnFeedbackAdd_Click);
            // 
            // label9
            // 
            this.label9.Location = new System.Drawing.Point(8, 8);
            this.label9.Name = "label9";
            this.label9.Size = new System.Drawing.Size(160, 23);
            this.label9.TabIndex = 0;
            this.label9.Text = "Select Feedback Files to Use:";
            // 
            // tabButtons
            // 
            this.tabButtons.Controls.Add(this.linkButtonsHelp);
            this.tabButtons.Controls.Add(this.btnBtnBrowse);
            this.tabButtons.Controls.Add(this.BtnUpdate);
            this.tabButtons.Controls.Add(this.BtnRemove);
            this.tabButtons.Controls.Add(this.BtnAdd);
            this.tabButtons.Controls.Add(this.listButtons);
            this.tabButtons.Controls.Add(this.BtnPic);
            this.tabButtons.Controls.Add(this.label8);
            this.tabButtons.Controls.Add(this.BtnText);
            this.tabButtons.Controls.Add(this.label7);
            this.tabButtons.Controls.Add(this.BtnResponseCat);
            this.tabButtons.Controls.Add(this.label6);
            this.tabButtons.Controls.Add(this.BtnFontSize);
            this.tabButtons.Controls.Add(this.label5);
            this.tabButtons.Controls.Add(this.BtnYLoc);
            this.tabButtons.Controls.Add(this.label4);
            this.tabButtons.Controls.Add(this.BtnYSize);
            this.tabButtons.Controls.Add(this.label3);
            this.tabButtons.Controls.Add(this.BtnXLoc);
            this.tabButtons.Controls.Add(this.label2);
            this.tabButtons.Controls.Add(this.BtnXSize);
            this.tabButtons.Controls.Add(this.label1);
            this.tabButtons.Location = new System.Drawing.Point(4, 22);
            this.tabButtons.Name = "tabButtons";
            this.tabButtons.Size = new System.Drawing.Size(576, 390);
            this.tabButtons.TabIndex = 6;
            this.tabButtons.Text = "Buttons";
            // 
            // linkButtonsHelp
            // 
            this.linkButtonsHelp.Location = new System.Drawing.Point(496, 8);
            this.linkButtonsHelp.Name = "linkButtonsHelp";
            this.linkButtonsHelp.Size = new System.Drawing.Size(40, 23);
            this.linkButtonsHelp.TabIndex = 52;
            this.linkButtonsHelp.TabStop = true;
            this.linkButtonsHelp.Text = "Help";
            this.linkButtonsHelp.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.linkButtonsHelp.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this.LinkClicked);
            // 
            // btnBtnBrowse
            // 
            this.btnBtnBrowse.Location = new System.Drawing.Point(409, 111);
            this.btnBtnBrowse.Name = "btnBtnBrowse";
            this.btnBtnBrowse.Size = new System.Drawing.Size(75, 23);
            this.btnBtnBrowse.TabIndex = 9;
            this.btnBtnBrowse.Text = "Browse";
            this.btnBtnBrowse.Click += new System.EventHandler(this.btnBtnBrowse_Click);
            // 
            // BtnUpdate
            // 
            this.BtnUpdate.Location = new System.Drawing.Point(235, 160);
            this.BtnUpdate.Name = "BtnUpdate";
            this.BtnUpdate.Size = new System.Drawing.Size(75, 23);
            this.BtnUpdate.TabIndex = 11;
            this.BtnUpdate.Text = "Update";
            this.BtnUpdate.Click += new System.EventHandler(this.BtnUpdate_Click);
            // 
            // BtnRemove
            // 
            this.BtnRemove.Location = new System.Drawing.Point(336, 160);
            this.BtnRemove.Name = "BtnRemove";
            this.BtnRemove.Size = new System.Drawing.Size(75, 23);
            this.BtnRemove.TabIndex = 12;
            this.BtnRemove.Text = "Remove";
            this.BtnRemove.Click += new System.EventHandler(this.BtnRemove_Click);
            // 
            // BtnAdd
            // 
            this.BtnAdd.Location = new System.Drawing.Point(134, 160);
            this.BtnAdd.Name = "BtnAdd";
            this.BtnAdd.Size = new System.Drawing.Size(75, 23);
            this.BtnAdd.TabIndex = 10;
            this.BtnAdd.Text = "Add";
            this.BtnAdd.Click += new System.EventHandler(this.BtnAdd_Click);
            // 
            // listButtons
            // 
            this.listButtons.Location = new System.Drawing.Point(8, 192);
            this.listButtons.Name = "listButtons";
            this.listButtons.Size = new System.Drawing.Size(528, 184);
            this.listButtons.TabIndex = 16;
            this.listButtons.UseCompatibleStateImageBehavior = false;
            this.listButtons.View = System.Windows.Forms.View.List;
            // 
            // BtnPic
            // 
            this.BtnPic.Location = new System.Drawing.Point(112, 112);
            this.BtnPic.Name = "BtnPic";
            this.BtnPic.Size = new System.Drawing.Size(288, 20);
            this.BtnPic.TabIndex = 8;
            // 
            // label8
            // 
            this.label8.Location = new System.Drawing.Point(8, 111);
            this.label8.Name = "label8";
            this.label8.Size = new System.Drawing.Size(100, 23);
            this.label8.TabIndex = 14;
            this.label8.Text = "Picture File:";
            this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnText
            // 
            this.BtnText.Location = new System.Drawing.Point(112, 88);
            this.BtnText.Name = "BtnText";
            this.BtnText.Size = new System.Drawing.Size(100, 20);
            this.BtnText.TabIndex = 7;
            // 
            // label7
            // 
            this.label7.Location = new System.Drawing.Point(8, 87);
            this.label7.Name = "label7";
            this.label7.Size = new System.Drawing.Size(100, 23);
            this.label7.TabIndex = 12;
            this.label7.Text = "Text:";
            this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnResponseCat
            // 
            this.BtnResponseCat.Location = new System.Drawing.Point(384, 64);
            this.BtnResponseCat.Name = "BtnResponseCat";
            this.BtnResponseCat.Size = new System.Drawing.Size(100, 20);
            this.BtnResponseCat.TabIndex = 6;
            // 
            // label6
            // 
            this.label6.Location = new System.Drawing.Point(264, 63);
            this.label6.Name = "label6";
            this.label6.Size = new System.Drawing.Size(112, 23);
            this.label6.TabIndex = 10;
            this.label6.Text = "Response Category:";
            this.label6.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnFontSize
            // 
            this.BtnFontSize.Location = new System.Drawing.Point(112, 64);
            this.BtnFontSize.Name = "BtnFontSize";
            this.BtnFontSize.Size = new System.Drawing.Size(100, 20);
            this.BtnFontSize.TabIndex = 5;
            // 
            // label5
            // 
            this.label5.Location = new System.Drawing.Point(8, 63);
            this.label5.Name = "label5";
            this.label5.Size = new System.Drawing.Size(100, 23);
            this.label5.TabIndex = 8;
            this.label5.Text = "FontSize:";
            this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnYLoc
            // 
            this.BtnYLoc.Location = new System.Drawing.Point(384, 40);
            this.BtnYLoc.Name = "BtnYLoc";
            this.BtnYLoc.Size = new System.Drawing.Size(100, 20);
            this.BtnYLoc.TabIndex = 4;
            // 
            // label4
            // 
            this.label4.Location = new System.Drawing.Point(280, 39);
            this.label4.Name = "label4";
            this.label4.Size = new System.Drawing.Size(100, 23);
            this.label4.TabIndex = 6;
            this.label4.Text = "YLocation:";
            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnYSize
            // 
            this.BtnYSize.Location = new System.Drawing.Point(384, 16);
            this.BtnYSize.Name = "BtnYSize";
            this.BtnYSize.Size = new System.Drawing.Size(100, 20);
            this.BtnYSize.TabIndex = 2;
            // 
            // label3
            // 
            this.label3.Location = new System.Drawing.Point(280, 15);
            this.label3.Name = "label3";
            this.label3.Size = new System.Drawing.Size(100, 23);
            this.label3.TabIndex = 4;
            this.label3.Text = "YSize:";
            this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnXLoc
            // 
            this.BtnXLoc.Location = new System.Drawing.Point(112, 40);
            this.BtnXLoc.Name = "BtnXLoc";
            this.BtnXLoc.Size = new System.Drawing.Size(100, 20);
            this.BtnXLoc.TabIndex = 3;
            // 
            // label2
            // 
            this.label2.Location = new System.Drawing.Point(8, 39);
            this.label2.Name = "label2";
            this.label2.Size = new System.Drawing.Size(100, 23);
            this.label2.TabIndex = 2;
            this.label2.Text = "XLocation:";
            this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // BtnXSize
            // 
            this.BtnXSize.Location = new System.Drawing.Point(112, 16);
            this.BtnXSize.Name = "BtnXSize";
            this.BtnXSize.Size = new System.Drawing.Size(100, 20);
            this.BtnXSize.TabIndex = 1;
            // 
            // label1
            // 
            this.label1.Location = new System.Drawing.Point(8, 15);
            this.label1.Name = "label1";
            this.label1.Size = new System.Drawing.Size(100, 23);
            this.label1.TabIndex = 0;
            this.label1.Text = "XSize:";
            this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            // 
            // tabComplex
            // 
            this.tabComplex.Controls.Add(this.treeComplex);
            this.tabComplex.Controls.Add(this.label11);
            this.tabComplex.Controls.Add(this.label10);
            this.tabComplex.Controls.Add(this.btnComplexRemove);
            this.tabComplex.Controls.Add(this.btnComplexAdd);
            this.tabComplex.Location = new System.Drawing.Point(4, 22);
            this.tabComplex.Name = "tabComplex";
            this.tabComplex.Size = new System.Drawing.Size(576, 390);
            this.tabComplex.TabIndex = 8;
            this.tabComplex.Text = "Complex Stimuli";
            // 
            // treeComplex
            // 
            this.treeComplex.Location = new System.Drawing.Point(48, 200);
            this.treeComplex.Name = "treeComplex";
            this.treeComplex.Size = new System.Drawing.Size(498, 184);
            this.treeComplex.TabIndex = 52;
            // 
            // label11
            // 
            this.label11.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.label11.Location = new System.Drawing.Point(16, 56);
            this.label11.Name = "label11";
            this.label11.Size = new System.Drawing.Size(552, 40);
            this.label11.TabIndex = 51;
            this.label11.Text = "Highlight a Complex Stim in the list and click the \'Remove\' button to remove a st" +
                "im from the .def file";
            // 
            // label10
            // 
            this.label10.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.label10.Location = new System.Drawing.Point(16, 32);
            this.label10.Name = "label10";
            this.label10.Size = new System.Drawing.Size(552, 24);
            this.label10.TabIndex = 50;
            this.label10.Text = "Click the \'Add\' button to start the Complex Stim Wizard.";
            // 
            // btnComplexRemove
            // 
            this.btnComplexRemove.Location = new System.Drawing.Point(344, 160);
            this.btnComplexRemove.Name = "btnComplexRemove";
            this.btnComplexRemove.Size = new System.Drawing.Size(75, 23);
            this.btnComplexRemove.TabIndex = 49;
            this.btnComplexRemove.Text = "Remove";
            this.btnComplexRemove.Click += new System.EventHandler(this.btnComplexRemove_Click);
            // 
            // btnComplexAdd
            // 
            this.btnComplexAdd.Location = new System.Drawing.Point(144, 160);
            this.btnComplexAdd.Name = "btnComplexAdd";
            this.btnComplexAdd.Size = new System.Drawing.Size(75, 23);
            this.btnComplexAdd.TabIndex = 48;
            this.btnComplexAdd.Text = "Add";
            this.btnComplexAdd.Click += new System.EventHandler(this.btnComplexAdd_Click);
            // 
            // mainMenu1
            // 
            this.mainMenu1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.menuItem1});
            // 
            // menuItem1
            // 
            this.menuItem1.Index = 0;
            this.menuItem1.MenuItems.AddRange(new System.Windows.Forms.MenuItem[] {
            this.FileNew,
            this.FileLoad,
            this.FileSave,
            this.FileSaveAs});
            this.menuItem1.Text = "File";
            // 
            // FileNew
            // 
            this.FileNew.Index = 0;
            this.FileNew.Text = "New";
            this.FileNew.Click += new System.EventHandler(this.FileNew_Click);
            // 
            // FileLoad
            // 
            this.FileLoad.Index = 1;
            this.FileLoad.Text = "Load";
            this.FileLoad.Click += new System.EventHandler(this.FileLoad_Click);
            // 
            // FileSave
            // 
            this.FileSave.Index = 2;
            this.FileSave.Text = "Save";
            this.FileSave.Click += new System.EventHandler(this.FileSave_Click);
            // 
            // FileSaveAs
            // 
            this.FileSaveAs.Index = 3;
            this.FileSaveAs.Text = "Save As";
            this.FileSaveAs.Click += new System.EventHandler(this.FileSaveAs_Click);
            // 
            // toolBarDef
            // 
            this.toolBarDef.Buttons.AddRange(new System.Windows.Forms.ToolBarButton[] {
            this.toolBarNew,
            this.toolBarOpen,
            this.toolBarSave,
            this.toolBarButton1,
            this.toolBarManual});
            this.toolBarDef.DropDownArrows = true;
            this.toolBarDef.ImageList = this.imageListDef;
            this.toolBarDef.Location = new System.Drawing.Point(0, 0);
            this.toolBarDef.Name = "toolBarDef";
            this.toolBarDef.ShowToolTips = true;
            this.toolBarDef.Size = new System.Drawing.Size(637, 28);
            this.toolBarDef.TabIndex = 1;
            this.toolBarDef.ButtonClick += new System.Windows.Forms.ToolBarButtonClickEventHandler(this.toolBarDef_ButtonClick);
            // 
            // toolBarNew
            // 
            this.toolBarNew.ImageIndex = 2;
            this.toolBarNew.Name = "toolBarNew";
            this.toolBarNew.ToolTipText = "New Def File";
            // 
            // toolBarOpen
            // 
            this.toolBarOpen.ImageIndex = 0;
            this.toolBarOpen.Name = "toolBarOpen";
            this.toolBarOpen.ToolTipText = "Open Def File";
            // 
            // toolBarSave
            // 
            this.toolBarSave.ImageIndex = 1;
            this.toolBarSave.Name = "toolBarSave";
            this.toolBarSave.ToolTipText = "Save Def File";
            // 
            // toolBarButton1
            // 
            this.toolBarButton1.Name = "toolBarButton1";
            this.toolBarButton1.Style = System.Windows.Forms.ToolBarButtonStyle.Separator;
            // 
            // toolBarManual
            // 
            this.toolBarManual.ImageIndex = 3;
            this.toolBarManual.Name = "toolBarManual";
            this.toolBarManual.ToolTipText = "Set Manual Location";
            // 
            // imageListDef
            // 
            this.imageListDef.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageListDef.ImageStream")));
            this.imageListDef.TransparentColor = System.Drawing.Color.Transparent;
            this.imageListDef.Images.SetKeyName(0, "");
            this.imageListDef.Images.SetKeyName(1, "");
            this.imageListDef.Images.SetKeyName(2, "");
            this.imageListDef.Images.SetKeyName(3, "");
            // 
            // statusBar1
            // 
            this.statusBar1.Location = new System.Drawing.Point(0, 501);
            this.statusBar1.Name = "statusBar1";
            this.statusBar1.Size = new System.Drawing.Size(637, 22);
            this.statusBar1.TabIndex = 2;
            this.statusBar1.Text = "statusBar1";
            // 
            // PS9lbl
            // 
            this.PS9lbl.Location = new System.Drawing.Point(272, 136);
            this.PS9lbl.Name = "PS9lbl";
            this.PS9lbl.Size = new System.Drawing.Size(160, 23);
            this.PS9lbl.TabIndex = 54;
            this.PS9lbl.Text = "Attenuation Mode";
            this.PS9lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.PS9lbl.Visible = false;
            // 
            // PS10lbl
            // 
            this.PS10lbl.Location = new System.Drawing.Point(272, 159);
            this.PS10lbl.Name = "PS10lbl";
            this.PS10lbl.Size = new System.Drawing.Size(160, 23);
            this.PS10lbl.TabIndex = 55;
            this.PS10lbl.Text = "Attenuate By";
            this.PS10lbl.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
            this.PS10lbl.Visible = false;
            // 
            // rdPeak
            // 
            this.rdPeak.AutoSize = true;
            this.rdPeak.Checked = true;
            this.rdPeak.Location = new System.Drawing.Point(3, 5);
            this.rdPeak.Name = "rdPeak";
            this.rdPeak.Size = new System.Drawing.Size(50, 17);
            this.rdPeak.TabIndex = 56;
            this.rdPeak.TabStop = true;
            this.rdPeak.Text = "Peak";
            this.rdPeak.UseVisualStyleBackColor = true;
            this.rdPeak.Visible = false;
            // 
            // rdRms
            // 
            this.rdRms.AutoSize = true;
            this.rdRms.Location = new System.Drawing.Point(56, 5);
            this.rdRms.Name = "rdRms";
            this.rdRms.Size = new System.Drawing.Size(49, 17);
            this.rdRms.TabIndex = 57;
            this.rdRms.Text = "RMS";
            this.rdRms.UseVisualStyleBackColor = true;
            this.rdRms.Visible = false;
            // 
            // tbAtteunate
            // 
            this.tbAtteunate.Location = new System.Drawing.Point(432, 161);
            this.tbAtteunate.Name = "tbAtteunate";
            this.tbAtteunate.Size = new System.Drawing.Size(100, 20);
            this.tbAtteunate.TabIndex = 58;
            this.tbAtteunate.Visible = false;
            // 
            // pnlMode
            // 
            this.pnlMode.Controls.Add(this.rdPeak);
            this.pnlMode.Controls.Add(this.rdRms);
            this.pnlMode.Location = new System.Drawing.Point(432, 136);
            this.pnlMode.Name = "pnlMode";
            this.pnlMode.Size = new System.Drawing.Size(108, 25);
            this.pnlMode.TabIndex = 59;
            // 
            // DefEditor
            // 
            this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
            this.ClientSize = new System.Drawing.Size(637, 523);
            this.Controls.Add(this.statusBar1);
            this.Controls.Add(this.toolBarDef);
            this.Controls.Add(this.tabControl1);
            this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
            this.Menu = this.mainMenu1;
            this.Name = "DefEditor";
            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
            this.Text = ".def File Editor";
            this.Load += new System.EventHandler(this.DefEditor_Load);
            this.tabControl1.ResumeLayout(false);
            this.tabConstants.ResumeLayout(false);
            this.tabConstants.PerformLayout();
            this.tabCL.ResumeLayout(false);
            this.tabCL.PerformLayout();
            this.tabPrimary.ResumeLayout(false);
            this.tabPrimary.PerformLayout();
            this.tabSecondary.ResumeLayout(false);
            this.tabSecondary.PerformLayout();
            this.tabPaired.ResumeLayout(false);
            this.tabPaired.PerformLayout();
            this.tabAdaptive.ResumeLayout(false);
            this.tabAdaptive.PerformLayout();
            this.tabResults.ResumeLayout(false);
            this.tabResults.PerformLayout();
            this.groupBox1.ResumeLayout(false);
            this.tabFeedback.ResumeLayout(false);
            this.groupBox2.ResumeLayout(false);
            this.groupBox2.PerformLayout();
            this.tabButtons.ResumeLayout(false);
            this.tabButtons.PerformLayout();
            this.tabComplex.ResumeLayout(false);
            this.pnlMode.ResumeLayout(false);
            this.pnlMode.PerformLayout();
            this.ResumeLayout(false);
            this.PerformLayout();

		}
		#endregion

		private void DefEditor_Closing(object sender, CancelEventArgs e)
		{
			if(main!=null)
				main.Show();
		}

		private void toolBarDef_ButtonClick(object sender, System.Windows.Forms.ToolBarButtonClickEventArgs e)
		{
			EventArgs ev = new EventArgs();
			switch(toolBarDef.Buttons.IndexOf(e.Button))
			{
				case 0:
					FileNew_Click(sender, ev);
					break;
				case 1:
					FileLoad_Click(sender,ev);
					break;
				case 2:
					FileSave_Click(sender,ev);
					break;
				case 3:
					//seperator
					break;
				case 4:
					SetManual();
					break;
			}
		}
		private void FileNew_Click(object sender, System.EventArgs e)
		{
			main.def = new Definitions();
			this.FillFields();
		}
		private void FileLoad_Click(object sender, System.EventArgs e)
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Init file (*.def)|*.def";
			dlg.Filter += "|All files|*.*";
			dlg.Multiselect = false;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				main.InitFile = new System.IO.FileInfo(dlg.FileName);
				SaveFile = new System.IO.FileInfo(dlg.FileName);
				//clear all fields
				main.def = new Definitions();
				FillFields();
				//load and display
				main.ReadInitFile(null);
				FillFields();
			}
		}

		private void FileSave_Click(object sender, System.EventArgs e)
		{
			if(SaveFile==null)
			{
				SaveFileDialog dlg = new SaveFileDialog();
				dlg.Filter = "Init file (*.def)|*.def";
				dlg.Filter += "|All files|*.*";
				dlg.OverwritePrompt = true;
				if(dlg.ShowDialog()!=DialogResult.OK)
				{	
					return;
				}
				SaveFile = new System.IO.FileInfo(dlg.FileName);
				int n = main.def.nFreqShapeSecondary;
				main.def = new Definitions();
				main.def.nFreqShapeSecondary = n;
			}
			WriteDefFile();
		}
		private void FileSaveAs_Click(object sender, System.EventArgs e)
		{
			SaveFileDialog dlg = new SaveFileDialog();
			dlg.Filter = "Init file (*.def)|*.def";
			dlg.Filter += "|All files|*.*";
			dlg.OverwritePrompt = true;
			if(dlg.ShowDialog()!=DialogResult.OK)
			{	
				return;
			}
			SaveFile = new System.IO.FileInfo(dlg.FileName);
			int n = main.def.nFreqShapeSecondary;
			main.def = new Definitions();
			main.def.nFreqShapeSecondary = n;
			WriteDefFile();
		}

		private void SetManual()
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Word Document (*.doc)|*.doc";
			dlg.Filter += "|All files|*.*";
			dlg.Multiselect = false;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				try
				{
					Microsoft.Win32.RegistryKey upper = Microsoft.Win32.Registry.CurrentUser.CreateSubKey("HAL");
					Microsoft.Win32.RegistryKey key = upper.CreateSubKey("Manual");
					key.SetValue("Manual",dlg.FileName);
					main.Manual = dlg.FileName;
				}
				catch(Exception)
				{
					return;
				}

			}
		}
		private bool WriteDefFile()
		{
			if(ReadFields()==false)
				return false;
			if(chkCL.Checked==true)
			{
				bool b = WriteCLDefFile();
				return b;
			}
			//constants
			StreamWriter wr = new StreamWriter(SaveFile.FullName,false);
			wr.WriteLine("%%%HAL definition file");
			wr.WriteLine("%%%Generated " + DateTime.Now.ToShortDateString());
			wr.WriteLine(string.Empty);
			if(main.def.bRandom==true)
				wr.WriteLine("Order.Primary: 1");
			else
				wr.WriteLine("Order.Primary: 0");
			wr.WriteLine("Order.Secondary: "+main.def.strSecondaryOrder);
			if(main.def.bSecondaryContinuous==true)
				wr.WriteLine("Stimuli.SecondaryContinuous: 1");
			else
				wr.WriteLine("Stimuli.SecondaryContinuous: 0");
			if(main.def.bMixSecondary)
				wr.WriteLine("mix.secondary: mix");
			else
				wr.WriteLine("mix.secondary: do not mix");
			wr.WriteLine("MaxLevel: " + main.def.nMaxLevel.ToString());
			wr.WriteLine("NumberOfTrials: " + main.def.nNumberOfTrials.ToString());
			wr.WriteLine("GameDelay: " + main.def.nGameDelay.ToString());
			wr.WriteLine("GameDelayType: " + main.def.nGameDelayType.ToString());
			wr.WriteLine("Timer: " + main.def.nTimer.ToString());
			wr.WriteLine("ISI.Length: " + main.def.nDelay.ToString());
			wr.WriteLine("ISI.Jitter: " + main.def.nJitter.ToString());
			if(main.def.bWaitForNextButton==true)
				wr.WriteLine("WaitForNextButton: 1");
			else
				wr.WriteLine("WaitForNextButton: 0");
			if(main.def.bCue==true)
				wr.WriteLine("Interval.Cue: 1");
			else
				wr.WriteLine("Interval.Cue: 0");
			if(main.def.bCatchTrial==true)
				wr.WriteLine("CatchTrial.Enabled: 1");
			else
				wr.WriteLine("CatchTrial.Enabled: 0");
			if(main.def.bBackToBackCatch==true)
				wr.WriteLine("CatchTrial.BackToBack: 1");
			else
				wr.WriteLine("CatchTrial.BackToBack: 0");
			wr.WriteLine("CatchTrial.Length: " + main.def.nCatchLength.ToString());
			wr.WriteLine("CatchTrial.Frequency: "+main.def.nCatchFreq.ToString());
			wr.WriteLine("Range.StepSize: " + main.def.nStepSize.ToString());
			wr.WriteLine("Range.Width: " + main.def.nRange.ToString());
			wr.WriteLine("Repetitions: " + main.def.nReps.ToString());
			if(main.def.bInterval==true)
				wr.WriteLine("Interval.Buttons: 1");
			else
				wr.WriteLine("Interval.Buttons: 0");
			wr.WriteLine("Interval.TimeOn: " + main.def.nIntervalLen.ToString());
			wr.WriteLine("Interval.Interval: " + main.def.nIntervalSpace.ToString());
			wr.WriteLine("ChangeFeedback: " + main.def.nChangeFeedback.ToString());
			//adaptive - method change, this might be easier
			if(Adaptive.Text=="Primary")
				wr.WriteLine("Adapt: Primary");
			else if(Adaptive.Text=="Secondary")
				wr.WriteLine("Adapt: Secondary");
			else if(Adaptive.Text=="Across Primary")
				wr.WriteLine("Adapt: Across Primary");
			else
				wr.WriteLine("Adapt: None");
			/*if(Adaptive.Text == "Primary")
				wr.WriteLine("PrimaryAdapt: Level");
			else if(Adaptive.Text == "Secondary")
				wr.WriteLine("SecondaryAdapt: Level");*/
			switch(Method.Text)
			{
				case "50":
					wr.WriteLine("Method: 1");
					break;
				case "70":
					wr.WriteLine("Method: 2");
					break;
				case "30":
					wr.WriteLine("Method: 3");
					break;
			}
			if(OnCorrect.Text == "Decrease Level")
				wr.WriteLine("DirOfChange: +");
			else
				wr.WriteLine("DirOfChange: -");
			wr.WriteLine("StepSize.Primary: " + PrimaryStep.Text);
			wr.WriteLine("StepSize.Secondary: " + SecondaryStep.Text);
			if(StopMode.Text == "StdErr")
				wr.WriteLine("Stop.Mode: 0");
			else if(StopMode.Text=="Reversals")
				wr.WriteLine("Stop.Mode: 1");
			else
				wr.WriteLine("Stop.Mode: 2");
			wr.WriteLine("Stop.StandardError: " + StandardError.Text);
			wr.WriteLine("Stop.PrimaryReversals: "+ NumOfReversals.Text);
			wr.WriteLine("Stop.SecondaryReversals: "+ NumOfStopReversals.Text);
			//primary stims
			for(int x=0;x<listPrimary.Items.Count;x++)
			{
				wr.WriteLine(listPrimary.Items[x].Text);
			}
			//Secondary stims
			for(int x=0;x<listSecondary.Items.Count;x++)
			{
				wr.WriteLine(listSecondary.Items[x].Text);
			}
			//Paired Stims
			for(int x=0;x<listPaired.Items.Count;x++)
			{
				wr.WriteLine(listPaired.Items[x].Text);
			}
			wr.WriteLine("PlayLRStereo :" +cbPlayLR.Checked.ToString());
			//Complex Stims
			for(int x=0;x<treeComplex.Nodes.Count;x++)
			{
				wr.WriteLine(treeComplex.Nodes[x].Text);
				foreach(TreeNode n in treeComplex.Nodes[x].Nodes)
				{
					wr.WriteLine("     "+n.Text);
				}
			}
			//buttons
			for(int x=0;x<listButtons.Items.Count;x++)
			{
				wr.WriteLine(listButtons.Items[x].Text);
			}
			//feedback
			for(int x=0;x<listFeedback.Items.Count;x++)
			{
				wr.WriteLine("FeedbackFile: "+listFeedback.Items[x].Text);
			}
			wr.WriteLine("FeedbackX: "+main.def.FeedbackLoc.X);
			wr.WriteLine("FeedbackY: "+main.def.FeedbackLoc.Y);
			wr.WriteLine("FeedbackWid: "+main.def.FeedbackSize.X);
			wr.WriteLine("FeedbackHgt: "+main.def.FeedbackSize.Y);
			//Results
			wr.WriteLine("Results: " + txtResults.Text);
			wr.WriteLine("FreqShapeSecondary: "+ main.def.nFreqShapeSecondary.ToString());
			//CL
			if(main.def.bAnchoredTrials==true)
				wr.WriteLine("CLAnchor: 1");
			else
				wr.WriteLine("CLAnchor: 0");

			wr.WriteLine("CLButtonsLayout: "+this.cmbButtonLayout.SelectedIndex);
			if(main.def.CLUseAdaptive == true) wr.WriteLine("CLUseAdaptive: 1");
			else wr.WriteLine("CLUseAdaptive: 0");

			
			wr.Flush();
			wr.Close();
			return true;
		}

		private bool WriteCLDefFile()
		{
			StreamWriter wr = new StreamWriter(SaveFile.FullName,false);
			wr.WriteLine("%%%HAL definition file");
			wr.WriteLine("%%%Generated " + DateTime.Now.ToShortDateString());
			wr.WriteLine(string.Empty);
			wr.WriteLine("CL: 1");
			if(main.def.bRandom==true)
				wr.WriteLine("Order.Primary: 1");
			else
				wr.WriteLine("Order.Primary: 0");
			wr.WriteLine("Repetitions: " + main.def.nReps.ToString());
			wr.WriteLine("ISI.Length: " + main.def.nDelay.ToString());
			wr.WriteLine("ISI.Jitter: " + main.def.nJitter.ToString());
			wr.WriteLine("MaxLevel: " + main.def.nMaxLevel.ToString());
			wr.WriteLine("CLButtons: " + main.def.nCLButtons.ToString());
			if(main.def.bAnchoredTrials==true)
				wr.WriteLine("CLAnchor: 1");
			else
				wr.WriteLine("CLAnchor: 0");
            wr.WriteLine("CLButtonsLayout: " + this.cmbButtonLayout.SelectedIndex);
			//primary stims
			for(int x=0;x<listPrimary.Items.Count;x++)
			{
				wr.WriteLine(listPrimary.Items[x].Text);
			}
			wr.Flush();
			wr.Close();
			return true;
		}


		#region FillDataFields
		public void FillFields()
		{
			if(SaveFile!=null)
				statusBar1.Text = SaveFile.FullName;
			else
				statusBar1.Text = string.Empty;
			if(main.def.bCL==true)
				this.chkCL.Checked = true;
			FillConstants();
			FillAdaptive();
			FillPrimaryStim();
			FillSecondaryStim();
			FillPairedStim();
			FillComplex();
			FillButtons();
			FillFeedback();
			FillResults();
			FillCL();
			main.def.strStimDirectory = string.Empty;
			SetCatch();
			SetInterval();
			SetAdaptive();
		}
		private void FillConstants()
		{
			if(main.def.bRandom==true)
				PrimaryOrder.Text = "Random";
			else
				PrimaryOrder.Text = "Fixed";
			SecondaryOrder.Text = main.def.strSecondaryOrder;
			if(main.def.bSecondaryContinuous==true)
				SecondaryContinuous.Text = "True";
			else
				SecondaryContinuous.Text = "False";
			if(main.def.bMixSecondary)
				this.cmbMixSecondary.SelectedIndex = 0;
			else
				this.cmbMixSecondary.SelectedIndex = 1;

			MaxLevel.Text = main.def.nMaxLevel.ToString();
			MaxTrials.Text = main.def.nNumberOfTrials.ToString();
			GameDelay.Text = main.def.nGameDelay.ToString();
			if(main.def.nGameDelayType==1)
				GameDelayType.Text = "1 Step every X Trials";
			else
				GameDelayType.Text = "Store and Show";
			Timer.Text = main.def.nTimer.ToString();
			ISI.Text = main.def.nDelay.ToString();
			Jitter.Text = main.def.nJitter.ToString();
			if(main.def.bWaitForNextButton==true)
				WaitForNext.Text = "True";
			else
				WaitForNext.Text = "False";
			if(main.def.bCue==true)
				Cue.Text = "True";
			else
				Cue.Text = "False";
			if(main.def.bCatchTrial==true)
				CatchTrials.Text = "True";
			else
				CatchTrials.Text = "False";
			if(main.def.bBackToBackCatch==true)
				BacktoBackCatch.Text = "True";
			else
				BacktoBackCatch.Text = "False";
			CatchLength.Text = main.def.nCatchLength.ToString();
			CatchFreq.Text = main.def.nCatchFreq.ToString();
			StepSize.Text = main.def.nStepSize.ToString();
			Range.Text = main.def.nRange.ToString();
			Reps.Text = main.def.nReps.ToString();
			if(main.def.bInterval==true)
				Interval.Text = "True";
			else
				Interval.Text = "False";
			IntervalLength.Text = main.def.nIntervalLen.ToString();
			IntervalSpace.Text = main.def.nIntervalSpace.ToString();
			txtChangeFeedback.Text=main.def.nChangeFeedback.ToString();
		}
		private void FillAdaptive()
		{
			if(main.def.nAdaptType==1)
				Adaptive.Text = "Primary";
			else if(main.def.nAdaptType==2)
				Adaptive.Text = "Secondary";
			else if(main.def.nAdaptType==3)
				Adaptive.Text = "Across Primary";
			else
				Adaptive.Text = "None";
			if(main.def.Methods.Count>=1)
			{
				int nMethod = (int) main.def.Methods[0];
				if(nMethod==1)
				{
					Method.Text = "50";
				}
				else if(nMethod==2)
				{
					Method.Text = "70";
				}
				else if(nMethod==3)
				{
					Method.Text = "30";
				}
			}
			if(main.def.bBandwidth==true)
				OnCorrect.Text = "Decrease Level";
			else
				OnCorrect.Text = "Increase Level";
			PrimaryStep.Text = main.def.nPrimaryStep.ToString();
			SecondaryStep.Text = main.def.nSecondaryStep.ToString();
			if(main.def.nStopMode==0)
				StopMode.Text = "StdErr";
			else if(main.def.nStopMode == 1)
				StopMode.Text = "Reversals";
			else
				StopMode.Text = "Both";
			StandardError.Text = main.def.dwStdErrVal.ToString();
			this.NumOfReversals.Text = main.def.nChangeReversals.ToString();
			this.NumOfStopReversals.Text = main.def.nStopReversals.ToString();
		}
		private void FillPrimaryStim()
		{
			listPrimary.Items.Clear();
			foreach(Stim s in main.def.PrimaryStims)
			{
				if(s is ComplexStim)
					continue;
				ListViewItem i = new ListViewItem();
				if(s.strType!="wave")
					i.Text = "Stimuli.Primary:"+s.strText;
				else
				{
					string strAmp = "peak";
					if(s.AmpType==WaveLib.AmplificationTypes.RMS)
						strAmp = "rms";
					else if(s.AmpType == AmplificationTypes.None)
						strAmp = "none";
				//	if(main.def.strStimDirectory.LastIndexOf(@"\")!=main.def.strStimDirectory.Length-1)
				//		main.def.strStimDirectory+=@"\";
					if(s.strStimDirectory.LastIndexOf(@"\")!=s.strStimDirectory.Length-1)
							s.strStimDirectory+=@"\";
					i.Text = string.Format("Stimuli.Primary: wave;{0}{1};{2};{3};{4};{5};{6}",
						s.strStimDirectory,s.strFile,s.strDesiredResponse,s.strInfo,
						s.nOrigin,s.strEar,strAmp);
				}
				listPrimary.Items.Add(i);
			}
		}
		private void FillSecondaryStim()
		{
			listSecondary.Items.Clear();
			foreach(Stim s in main.def.SecondaryStims)
			{
				if(s is ComplexStim)
					continue;
				ListViewItem i = new ListViewItem();
				if(s.strType!="wave")
					i.Text = "Stimuli.Secondary:"+s.strText;
				else
				{
					string strAmp = "peak";
					if(s.AmpType==AmplificationTypes.RMS)
						strAmp = "rms";
					else if(s.AmpType == AmplificationTypes.None)
						strAmp = "none";
					if(s.strStimDirectory.LastIndexOf(@"\")!=s.strStimDirectory.Length-1)
						s.strStimDirectory+=@"\";

					i.Text = string.Format("Stimuli.Secondary: wave;{0}{1};{2};{3};{4};{5};{6}",
						s.strStimDirectory,s.strFile,s.strDesiredResponse,s.strInfo,
						s.nOrigin,s.strEar,strAmp);
				}
				listSecondary.Items.Add(i);
			}
		}
		private void FillPairedStim()
		{
			listPaired.Items.Clear();
			cbPlayLR.Checked = main.def.bPlayLRStereo;
			foreach(Stim s in main.def.PairedStims)
			{
				ListViewItem i = new ListViewItem();
				if(s.strType=="wave")
				{
					string strAmp = "peak";
					if(s.AmpType==AmplificationTypes.RMS)
						strAmp = "rms";
					else if (s.AmpType == AmplificationTypes.None)
						strAmp = "none";
					i.Text = string.Format("Stimuli.Paired: wave;{0};{1};{2};{3};{4};{5}",
						s.strStimDirectory,s.strDesiredResponse,s.strInfo,
						s.nOrigin,s.strEar,strAmp);
					txtPairedFolder.Text = s.strStimDirectory;
					txtPaired1.Text = s.strDesiredResponse;
					txtPaired2.Text = s.strInfo;
					txtPaired3.Text = s.nOrigin.ToString();
					txtPaired4.Text = s.strEar;
					cmbAmpType.Text = strAmp;
				}
				else if(s.strType.Equals("tone"))
				{
					string strAmp = "peak";
					if(s.AmpType==AmplificationTypes.RMS)
						strAmp = "rms";
					else if (s.AmpType == AmplificationTypes.None)
						strAmp = "none";
					i.Text = string.Format("Stimuli.Paired: tone;{0};{1};{2};{3};{4};{5}",
						main.def.strStimDirectory,s.strDesiredResponse,s.strInfo,
						s.nOrigin,s.strEar,strAmp);
					txtPairedFolder.Text = s.strFile;
					txtPaired1.Text = s.strDesiredResponse;
					txtPaired2.Text = s.strInfo;
					txtPaired3.Text = s.nOrigin.ToString();
					txtPaired4.Text = s.strEar;
					 
				}
				listPaired.Items.Add(i);
			}
		}
		private void FillComplex()
		{
			treeComplex.Nodes.Clear();
			foreach(Stim s in main.def.PrimaryStims)
			{
				if(s is ComplexStim)
				{
					ComplexStim cs = (ComplexStim) s;
					DisplayComplex("Stimuli.Primary",cs);
				}
			}
			foreach(Stim s in main.def.SecondaryStims)
			{
				if(s is ComplexStim)
				{
					ComplexStim cs = (ComplexStim) s;
					DisplayComplex("Stimuli.Secondary",cs);
				}
			}
		}
		private void FillButtons()
		{
			listButtons.Items.Clear();
			foreach(Button b in main.def.Buttons)
			{
				ButtonTag bt = (ButtonTag) b.Tag;
				//BUTTON: XSIZE ; YSIZE ; XLOC ; YLOC ;FontSize; Response Category ; TEXT ; Picture file (full path)
				ListViewItem i = new ListViewItem();
				i.Text = string.Format("Button:{0};{1};{2};{3};{4};{5};{6};\"{7}\"",
					b.Size.Width,b.Size.Height,b.Location.X,b.Location.Y,
					b.Font.Size,bt.strCat,b.Text,bt.strPic);
				listButtons.Items.Add(i);
			}
		}
		private void FillFeedback()
		{
			listFeedback.Items.Clear();
			foreach(string s in main.def.Feedback)
			{
				ListViewItem i = new ListViewItem();
				if(main.def.strFeedbackDir.Length>0)
				{
					i.Text = main.def.strFeedbackDir+s;
				}
				else
					i.Text = s;
				listFeedback.Items.Add(i);
			}
			txtFeedX.Text = main.def.FeedbackLoc.X.ToString();
			txtFeedY.Text = main.def.FeedbackLoc.Y.ToString();
			txtFeedWid.Text = main.def.FeedbackSize.X.ToString();
			txtFeedHgt.Text= main.def.FeedbackSize.Y.ToString();
			
		}
	
		private void FillResults()
		{
			ResPerf.Checked = false;
			ResFreq.Checked = false;
			ResEar.Checked = false;
			ResMethod.Checked = false;
			ResPrimary.Checked = false;
			ResSecondary.Checked = false;
			ResStimCat.Checked = false;
			ResAltCat.Checked = false;
			foreach(string s in main.def.listRes)
			{
				string str = s.ToLower().Trim();
				switch(str)
				{
					case "perf":
						ResPerf.Checked = true;
						break;
					case "freq":
						ResFreq.Checked = true;
						break;
					case "ear":
						ResEar.Checked = true;
						break;
					case "method":
						ResMethod.Checked = true;
						break;
					case "primarystim":
						ResPrimary.Checked = true;
						break;
					case "secondarystim":
						ResSecondary.Checked = true;
						break;
					case "stimcat":
						ResStimCat.Checked = true;
						break;
					case "altcat":
						ResAltCat.Checked = true;
						break;
				}
			}
			txtResults.Text = string.Empty;
			foreach(string s in main.def.listRes)
			{
				txtResults.Text+=s+";";
			}
		}
		private void FillCL()
		{
			if(main.def.bRandom==true)
				CLPrimaryOrder.Text="Random";
			else
				CLPrimaryOrder.Text="Fixed";
			CLMaxLevel.Text = main.def.nMaxLevel.ToString();
			CLReps.Text = main.def.nReps.ToString();
			CLIsi.Text = main.def.nDelay.ToString();
			CLIsiJitter.Text = main.def.nJitter.ToString();
			CLButtons.Text = main.def.nCLButtons.ToString();
            cmbButtonLayout.SelectedIndex = main.def.CLButtonsLayout;  
			if(main.def.bAnchoredTrials==true)
				CLAnchored.Text = "Yes";
			else
				CLAnchored.Text = "No";
		}
		#endregion
		#region ReadDataFields
		private bool ReadFields()
		{
			ReadConstants();
			ReadAdaptive();
			ReadPrimaryStim();
			ReadSecondaryStim();
			ReadPairedStim();
			ReadButtons();
			ReadFeedback();
			ReadResults();
			ReadCL();
			return true;
		}
		private bool ReadConstants()
		{
			try
			{
				if(PrimaryOrder.Text=="Random")
					main.def.bRandom = true;
				else
					main.def.bRandom = false;
				main.def.strSecondaryOrder = SecondaryOrder.Text;
				if(SecondaryContinuous.Text == "True")
					main.def.bSecondaryContinuous=true;
				else
					main.def.bSecondaryContinuous=false;
				if(this.cmbMixSecondary.SelectedIndex==0)
					main.def.bMixSecondary=true;
				else
					main.def.bMixSecondary=false;

				main.def.nMaxLevel = int.Parse(MaxLevel.Text);
				main.def.nNumberOfTrials = int.Parse(MaxTrials.Text);
				main.def.nGameDelay = int.Parse(GameDelay.Text);
				if(GameDelayType.Text == "1 Step every X Trials")
					main.def.nGameDelayType = 1;
				else
					main.def.nGameDelayType = 0;
				main.def.nTimer = int.Parse(Timer.Text);
				main.def.nDelay = int.Parse(ISI.Text);
				main.def.nJitter = int.Parse(Jitter.Text);
				if(WaitForNext.Text == "True")
					main.def.bWaitForNextButton = true;
				else
					main.def.bWaitForNextButton = false;

				if(Cue.Text == "True")
					main.def.bCue = true;
				else
					main.def.bCue = false;

				if(CatchTrials.Text == "True")
					main.def.bCatchTrial=true;
				else
					main.def.bCatchTrial = false;
				if(BacktoBackCatch.Text == "True")
					main.def.bBackToBackCatch = true;
				else
					main.def.bBackToBackCatch = false;
				main.def.nCatchLength = int.Parse(CatchLength.Text);
				main.def.nCatchFreq = int.Parse(CatchFreq.Text);
				main.def.nStepSize = int.Parse(StepSize.Text);
				main.def.nRange = int.Parse(Range.Text);
				main.def.nReps = int.Parse(Reps.Text);
				main.def.nChangeFeedback = int.Parse(txtChangeFeedback.Text);
				if(Interval.Text == "True")
					main.def.bInterval = true;
				else
					main.def.bInterval = false;
				main.def.nIntervalLen = int.Parse(IntervalLength.Text);
				main.def.nIntervalSpace = int.Parse(IntervalSpace.Text);
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;

		}
		private bool ReadAdaptive()
		{
			try
			{
				if(Adaptive.Text == "Primary")
					main.def.nAdaptType=1;
				else if(Adaptive.Text == "Secondary")
					main.def.nAdaptType=2;
				else if(Adaptive.Text == "Across Primary")
					main.def.nAdaptType=3;
				else
					main.def.nAdaptType=0;

				if(Adaptive.Text=="Secondary"&&main.def.strSecondaryOrder=="RandomInterval")
				{
					MessageBox.Show("You cannot use Secondary Adaptive and Secondary Order:RandomInterval or Secondary Order:RandomTrial together.");
				}

				switch(Method.Text)
				{
					case "50":
						main.def.Methods.Add(1);
						break;
					case "70":
						main.def.Methods.Add(2);
						break;
					case "30":
						main.def.Methods.Add(3);
						break;
				}
				if(OnCorrect.Text == "Decrease Level")
					main.def.bBandwidth = true;
				else
					main.def.bBandwidth = false;
				main.def.nPrimaryStep = int.Parse(PrimaryStep.Text);
				main.def.nSecondaryStep = int.Parse(SecondaryStep.Text);
				if(StopMode.Text == "StdErr")
					main.def.nStopMode = 0;
				else if(StopMode.Text == "Reversals")
					main.def.nStopMode = 1;
				else
					main.def.nStopMode = 2;
				main.def.dwStdErrVal = double.Parse(StandardError.Text);
				main.def.nChangeReversals = int.Parse(NumOfReversals.Text);
				main.def.nStopReversals = int.Parse(NumOfStopReversals.Text);
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;
		}
		private bool ReadPrimaryStim()
		{
			try
			{
				main.def.PrimaryStims.Clear();
				for(int x=0;x<listPrimary.Items.Count;x++)
				{
					string str = listPrimary.Items[x].Text;
					str = str.Replace("Stimuli.Primary:","");//parseprimary assumes PrimaryStim has been stripped out
					main.ParsePrimaryStimLine(str);
				}
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;
		}
		private bool ReadSecondaryStim()
		{
			try
			{
				main.def.SecondaryStims.Clear();
				for(int x=0;x<listSecondary.Items.Count;x++)
				{
					string str = listSecondary.Items[x].Text;
					str = str.Replace("Stimuli.Secondary:","");//parsesecondary assumes SecondaryStim has been stripped out
					main.ParseSecondaryStimLine(str);
				}
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;
		}
		private bool ReadPairedStim()
		{
			try
			{
				main.def.PairedStims.Clear();
				for(int x=0;x<listPaired.Items.Count;x++)
				{
					string str = listPaired.Items[0].Text;
					str = str.Replace("Stimuli.Paired:","");
					main.ParsePairedStimLine(str);
				}

			}
			catch (Exception err)
			{
				MessageBox.Show("Error: "+ err.Message);
				return false;
			}
			return true;
		}
		private bool ReadButtons()
		{
			try
			{
				main.def.Buttons.Clear();
				for(int x=0;x<listButtons.Items.Count;x++)
				{
					string str = listButtons.Items[x].Text;
					main.ParseButton(str);
				}
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;
			
		}
		private bool ReadFeedback()
		{
			try
			{
				main.def.Feedback.Clear();
				for(int x=0;x<listFeedback.Items.Count;x++)
				{
					main.def.Feedback.Add(listFeedback.Items[x].Text);
				}
				if(txtFeedWid.Text.Trim()=="")txtFeedWid.Text="500";
				if(txtFeedHgt.Text.Trim()=="")txtFeedHgt.Text="400";
				if(txtFeedX.Text.Trim()=="")txtFeedX.Text="200";
				if(txtFeedY.Text.Trim()=="")txtFeedY.Text="10";
				main.def.FeedbackSize.X =  int.Parse(txtFeedWid.Text);
				main.def.FeedbackSize.Y = int.Parse(txtFeedHgt.Text);
				main.def.FeedbackLoc.X = int.Parse(txtFeedX.Text);
				main.def.FeedbackLoc.Y = int.Parse(txtFeedY.Text);
			}
			catch(Exception err)
			{
				MessageBox.Show("Error: " + err.Message);
				return false;
			}
			return true;
			
		}
	
		private bool ReadResults()
		{
			if(ResPerf.Checked==true)
				main.def.listRes.Add("perf");
			if(ResFreq.Checked==true)
				main.def.listRes.Add("freq");
			if(ResEar.Checked==true)
				main.def.listRes.Add("ear");
			if(ResMethod.Checked==true)
				main.def.listRes.Add("method");
			if(ResPrimary.Checked==true)
				main.def.listRes.Add("primarystim");
			if(ResSecondary.Checked==true)
				main.def.listRes.Add("secondarystim");
			if(ResStimCat.Checked==true)
				main.def.listRes.Add("stimcat");
			if(ResAltCat.Checked==true)
				main.def.listRes.Add("altcat");
			
			return true;
		}
		private void ReadCL()
		{
			//get this one either way, just 'cause
			if(CLAnchored.Text=="Yes")
				main.def.bAnchoredTrials = true;
			else
				main.def.bAnchoredTrials = false;

			if(chkCL.Checked==false)
				return;//if it's not a CL, don't overwrite any data
			if(CLPrimaryOrder.Text=="Random")
				main.def.bRandom = true;
			else
				main.def.bRandom = false;
			main.def.nMaxLevel = int.Parse(CLMaxLevel.Text);
			main.def.nReps = int.Parse(CLReps.Text);
			main.def.nDelay = int.Parse(CLIsi.Text);
			main.def.nJitter = int.Parse(CLIsiJitter.Text);
			main.def.nCLButtons = int.Parse(CLButtons.Text);
			main.def.CLUseAdaptive = Convert.ToBoolean( cmbUseAdaptive.SelectedIndex);
			main.def.CLButtonsLayout = cmbButtonLayout.SelectedIndex;
            

			if(main.def.nCLButtons<7)
			{
				MessageBox.Show("Must have at least 7 buttons in Categorical Loudness!\r\nSetting Number of Buttons to 7.",
					"Not enough buttons!",MessageBoxButtons.OK,MessageBoxIcon.Warning);
				main.def.nCLButtons = 7;
			}
			

		}
		#endregion
		#region TabPrimaryStim
		private void PrimaryStim_CheckedChanged(object sender, EventArgs e)
		{
			//Alter the fields shown to match the parameters for that stim type
			this.PS1txt.Size = new Size(100,20);
			btnPSBrowse.Visible = false;
            

			if(rdoPsTone.Checked == true)
			{
                ShowAttuenateParameters();

				PS1lbl.Visible = true;
				PS2lbl.Visible = true;
				PS3lbl.Visible = true;
				PS4lbl.Visible = true;
				PS5lbl.Visible = true;
				PS6lbl.Visible = true;
				PS7lbl.Visible = true;
				PS1txt.Visible = true;
				PS2txt.Visible = true;
				PS3txt.Visible = true;
				PS4txt.Visible = true;
				PS5txt.Visible = true;
				PS6txt.Visible = true;
				PS7txt.Visible = true;
				//freq ; length ms ; rise ms ; fall ms ; ear; initial level (dB)
				PS1lbl.Text = "Frequency:";
				PS2lbl.Text = "Length (ms):";
				PS3lbl.Text = "Rise Time (ms):";
				PS4lbl.Text = "Fall Time (ms):";
				PS5lbl.Text = "Ear:";
				PS6lbl.Text = "Initial Level:";
				PS7lbl.Text = "Phase:";
				PS1txt.Text = "1000";
				PS2txt.Text = "1000";
				PS3txt.Text = "20";
				PS4txt.Text = "20";
				PS5txt.Text = "Both";
				PS6txt.Text = "60";
				PS7txt.Text = "0";
				PS8lbl.Visible = false;
				PS8txt.Visible = false;
			}
			else if(rdoPsPulse.Checked == true)
			{
                HideAttuenateParameters();
                PS1lbl.Visible = true;
				PS2lbl.Visible = true;
				PS3lbl.Visible = true;
				PS4lbl.Visible = true;
				PS5lbl.Visible = true;
				PS6lbl.Visible = true;
				PS7lbl.Visible = true;
				PS8lbl.Visible = true;
				PS1txt.Visible = true;
				PS2txt.Visible = true;
				PS3txt.Visible = true;
				PS4txt.Visible = true;
				PS5txt.Visible = true;
				PS6txt.Visible = true;
				PS7txt.Visible = true;
				PS8txt.Visible = true;
				//freq  ; length of each pulse ; interval ; rise ; fall ; ear ; initial level (dB)
				PS1lbl.Text = "Frequency:";
				PS2lbl.Text = "Pulse Length (ms):";
				PS3lbl.Text = "Interval (ms):";
				PS4lbl.Text = "Rise Time (ms):";
				PS5lbl.Text = "Fall Time (ms):";
				PS6lbl.Text = "Ear:";
				PS7lbl.Text = "Initial Level:";
				PS8lbl.Text = "Phase:";
				PS1txt.Text = "1000";
				PS2txt.Text = "300";
				PS3txt.Text = "50";
				PS4txt.Text = "20";
				PS5txt.Text = "20";
				PS6txt.Text = "Both";
				PS7txt.Text = "60";
				PS8txt.Text = "0";
			}
			else if(rdoPsNbn.Checked == true)
			{
                HideAttuenateParameters();
                PS1lbl.Visible = true;
				PS2lbl.Visible = true;
				PS3lbl.Visible = true;
				PS4lbl.Visible = true;
				PS5lbl.Visible = true;
				PS6lbl.Visible = true;
				PS7lbl.Visible = true;
				PS1txt.Visible = true;
				PS2txt.Visible = true;
				PS3txt.Visible = true;
				PS4txt.Visible = true;
				PS5txt.Visible = true;
				PS6txt.Visible = true;
				PS7txt.Visible = true;
				//center freq ; bw(in fraction of octave) ; length ms ; rise ms ; fall ms ; ear ; initial level (dB)
				PS1lbl.Text = "Center Frequency:";
				PS2lbl.Text = "BW (fraction of an octave):";
				PS3lbl.Text = "Length (ms):";
				PS4lbl.Text = "Rise Time (ms):";
				PS5lbl.Text = "Fall Time (ms):";
				PS6lbl.Text = "Ear:";
				PS7lbl.Text = "Initial Level:";
				PS1txt.Text = "1000";
				PS2txt.Text = "3";
				PS3txt.Text = "1000";
				PS4txt.Text = "20";
				PS5txt.Text = "20";
				PS6txt.Text = "Both";
				PS7txt.Text = "60";
				PS8lbl.Visible = false;
				PS8txt.Visible = false;
			}
			else if(rdoPsPnbn.Checked == true)
			{
                HideAttuenateParameters();
				PS1lbl.Visible = true;
				PS2lbl.Visible = true;
				PS3lbl.Visible = true;
				PS4lbl.Visible = true;
				PS5lbl.Visible = true;
				PS6lbl.Visible = true;
				PS7lbl.Visible = true;
				PS8lbl.Visible = true;
				PS1txt.Visible = true;
				PS2txt.Visible = true;
				PS3txt.Visible = true;
				PS4txt.Visible = true;
				PS5txt.Visible = true;
				PS6txt.Visible = true;
				PS7txt.Visible = true;
				PS8txt.Visible = true;
				//center freq ; bw(in fraction of octave) ; length of each pulse; interval ; rise ; fall ; ear ; initial level (dB)
				PS1lbl.Text = "Center Frequency:";
				PS2lbl.Text = "BW (fraction of an octave):";
				PS3lbl.Text = "Length of Pulse(ms):";
				PS4lbl.Text = "Interval:";
				PS5lbl.Text = "Rise Time (ms):";
				PS6lbl.Text = "Fall Time (ms):";
				PS7lbl.Text = "Ear:";
				PS8lbl.Text = "Initial Level:";
				PS1txt.Text = "1000";
				PS2txt.Text = "3";
				PS3txt.Text = "300";
				PS4txt.Text = "50";
				PS5txt.Text = "20";
				PS6txt.Text = "20";
				PS7txt.Text = "Both";
				PS8txt.Text = "60";
			}
			else if(rdoPsWav.Checked==true)
			{
                HideAttuenateParameters();
				PS1lbl.Visible = true;
				PS2lbl.Visible = true;
				PS3lbl.Visible = true;
				PS4lbl.Visible = true;
				PS6lbl.Visible = true;
				PS7lbl.Visible = true;
				PS1txt.Visible = true;
				PS2txt.Visible = true;
				PS3txt.Visible = true;
				PS4txt.Visible = true;
				PS6txt.Visible = true;
				PS7txt.Visible = true;
				this.PS1txt.Size = new Size(300,20);
				btnPSBrowse.Visible = true;
				//file ; category ; Response ; intial level ; ear(s) ; amplification type
				PS1lbl.Text = @"File:";
				PS2lbl.Text = "Response Category:";
				PS3lbl.Text = "Additional Info:";
				PS4lbl.Text = "Initial Level:";
				PS6lbl.Text = "Ear:";
				PS7lbl.Text = "Amplitude:";
				PS1txt.Text = "";
				PS2txt.Text = "1";
				PS3txt.Text = "Adult";
				PS4txt.Text = "60";
				PS6txt.Text = "Both";
				PS7txt.Text = "None";
				PS5lbl.Visible = false;
				PS5txt.Visible = false;
				PS8lbl.Visible = false;
				PS8txt.Visible = false;
			}

		}

        private void HideAttuenateParameters()
        {
            PS10lbl.Visible = false;
            PS9lbl.Visible = false;
            rdPeak.Visible = false;
            rdRms.Visible = false;
            tbAtteunate.Visible = false;
            pnlMode.Visible = false;
            
        }

        private void ShowAttuenateParameters()
        {
            PS10lbl.Visible = true; 
            PS9lbl.Visible = true;
            rdPeak.Visible = true; ;
            rdRms.Visible = true ;
            tbAtteunate.Visible = true;
            pnlMode.Visible = true;

        }



		private void btnPSBrowse_Click(object sender, System.EventArgs e)
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Wav file (*.wav)|*.wav";
			dlg.Filter += "|All files|*.*";
			dlg.Multiselect = true;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				PS1txt.Text = string.Empty;
				for(int x=0;x<dlg.FileNames.Length;x++)
				{
					PS1txt.Text += dlg.FileNames[x];
					PS1txt.Text+=";";
				}
				int lastIn = PS1txt.Text.LastIndexOf(";");
				if (lastIn > 0) PS1txt.Text=PS1txt.Text.Remove(lastIn,1);
				PS1txt.Tag = dlg.FileNames;
			}
		}

		private void btnPSAdd_Click(object sender, System.EventArgs e)
		{
			//Add the data in the text boxes to the list
			//What type of stim is it?
			ListViewItem i = GetPrimaryListItem(true);
			if(i.Text.Length>0)
				listPrimary.Items.Add(i);
		}
		private void btnPSRemove_Click(object sender, System.EventArgs e)
		{
			if(listPrimary.SelectedItems.Count<=0)
				return;
			while(listPrimary.SelectedItems.Count>0)
			{
				listPrimary.Items.Remove(listPrimary.SelectedItems[0]);
			}
		}

		private void btnPSUpdate_Click(object sender, System.EventArgs e)
		{
			if(listPrimary.SelectedItems.Count<=0)
				return;
			ListViewItem i = GetPrimaryListItem(false);
			if(i.Text.Length>0)
			{
				int n = listPrimary.SelectedIndices[0];
				listPrimary.Items.RemoveAt(n);
				listPrimary.Items.Insert(n,i);
			}
		}
		private ListViewItem GetPrimaryListItem(bool bNew)
		{
			ListViewItem i = new ListViewItem();
			i.Text = string.Empty;
			if(rdoPsTone.Checked==true)
			{
				i.Text = string.Format("Stimuli.Primary:tone;{0};{1};{2};{3};{4};{5};{6};{7};{8}",
					PS1txt.Text,PS2txt.Text,PS3txt.Text,PS4txt.Text,PS5txt.Text,PS6txt.Text,PS7txt.Text,rdPeak.Checked? "Peak": "RMS",tbAtteunate.Text);
			}
			else if(rdoPsPulse.Checked==true)
			{
				i.Text = string.Format("Stimuli.Primary:pulse;{0};{1};{2};{3};{4};{5};{6};{7}",
					PS1txt.Text,PS2txt.Text,PS3txt.Text,PS4txt.Text,PS5txt.Text,PS6txt.Text,PS7txt.Text,PS8txt.Text);
			}
			else if(rdoPsNbn.Checked==true)
			{
				i.Text = string.Format("Stimuli.Primary:nbn;{0};{1};{2};{3};{4};{5};{6}",
					PS1txt.Text,PS2txt.Text,PS3txt.Text,PS4txt.Text,PS5txt.Text,PS6txt.Text,PS7txt.Text);

			}
			else if(rdoPsPnbn.Checked==true)
			{
				i.Text = string.Format("Stimuli.Primary:pnbn;{0};{1};{2};{3};{4};{5};{6};{7}",
					PS1txt.Text,PS2txt.Text,PS3txt.Text,PS4txt.Text,PS5txt.Text,PS6txt.Text,PS7txt.Text,PS8txt.Text);

			}
			else if(rdoPsWav.Checked==true)
			{
				if(PS1txt.Text.Length<=0)
					return null;
				if(bNew==true)
				{
					string[] str = (string[]) PS1txt.Tag;
					for(int x=0;x<str.Length;x++)
					{
						i.Text = string.Format("Stimuli.Primary:wave;{0};{1};{2};{3};{4};{5}",
							str[x],PS2txt.Text,PS3txt.Text,PS4txt.Text,PS6txt.Text,PS7txt.Text);
						if(str.Length>1)
						{
							listPrimary.Items.Add(i);
							i = new ListViewItem();
						}
					}
				}
				else
				{
					i.Text = string.Format("Stimuli.Primary:wave;{0};{1};{2};{3};{4};{5}",
						PS1txt.Text,PS2txt.Text,PS3txt.Text,PS4txt.Text,PS6txt.Text,PS7txt.Text);
				}

			}
			return i;
		}
		private void listPrimary_Click(object sender, EventArgs e)
		{
			//read line and parse into fields, display in textboxes.
			if(listPrimary.SelectedItems.Count<=0)
				return;
			string str = listPrimary.SelectedItems[0].Text;
			string[] arrIn;
			string[] arr = new string[10];
			char[] szSeps = {':',';'};
			arrIn = str.Split(szSeps, StringSplitOptions.None);
			string strType = arrIn[1].ToLower().Trim();
			//commonly used
			PS1txt.Text = arrIn[2].Trim();
			PS2txt.Text = arrIn[3].Trim();
			PS3txt.Text = arrIn[4].Trim();
			PS4txt.Text = arrIn[5].Trim();
			PS5txt.Text = arrIn[6].Trim();

            if (arrIn.Length > 9)
            {
                if (arrIn[9].Trim().Equals("PEAK", StringComparison.OrdinalIgnoreCase))
                {

                    rdPeak.Checked = true;
                    rdRms.Checked = false;
                }
                else
                {
                    rdPeak.Checked = false;
                    rdRms.Checked = true;
                }
            }

            if (arrIn.Length > 10)
            {
                tbAtteunate.Text = arrIn[10].Trim();
            }

			if(arrIn.Length>7)
				PS6txt.Text = arrIn[7].Trim();
			if(arrIn.Length>8)
				PS7txt.Text = arrIn[8].Trim();
			switch(strType)
			{
				case "tone":
					rdoPsTone.Checked = true;
					break;
				case "pulse":
					rdoPsPulse.Checked = true;
					if(arrIn.Length>9)
						PS8txt.Text = arrIn[9].Trim();
					break;
				case "nbn":
					rdoPsNbn.Checked = true;
					PS7txt.Text = arrIn[8].Trim();
					break;
				case "pnbn":
					rdoPsPnbn.Checked = true;
					PS7txt.Text = arrIn[8].Trim();
					PS8txt.Text = arrIn[9].Trim();
					break;
				case "wave":
					//have to handle differently because of the c: factor
					//find first colon
					int n = str.IndexOf(":",0);
					str = str.Substring(n);//remove "PrimaryStim:"
					char[] sz = {';'};//now, split on ; in order to keep c:\filename together
					arrIn = str.Split(sz,7);
					rdoPsWav.Checked = true;
					if(main.def!=null)
					{
						//for old style that used StimDirectory parameter
						if(main.def.strStimDirectory.Length>0)
							PS1txt.Text = main.def.strStimDirectory.Trim() + arrIn[1].Trim();
						else
							PS1txt.Text = arrIn[1].Trim();
					}
					else
						PS1txt.Text = arrIn[1].Trim();
					string[] sa = new string[1];
					sa[0] = PS1txt.Text;
					PS1txt.Tag = sa;
					PS2txt.Text = arrIn[2].Trim();
					PS3txt.Text = arrIn[3].Trim();
					PS4txt.Text = arrIn[4].Trim();
					PS6txt.Text = arrIn[5].Trim();
					PS7txt.Text = arrIn[6].Trim();
					break;
			}
		}
		private void btnPrimaryUp_Click(object sender, System.EventArgs e)
		{
			if(listPrimary.SelectedItems.Count<=0)
				return;
			for(int z=0;z<listPrimary.SelectedItems.Count;z++)
			{
				int n = listPrimary.SelectedItems[z].Index;
				ListViewItem i = listPrimary.Items[n];
				listPrimary.Items[n].Remove();
				n--;
				if(n<0)
					n = 0;
				listPrimary.Items.Insert(n,i);
				listPrimary.Items[n].Selected = true;
			}
		}

		private void btnPrimaryDown_Click(object sender, System.EventArgs e)
		{
			if(listPrimary.SelectedItems.Count<=0)
				return;
			for(int z=listPrimary.SelectedItems.Count-1;z>=0;z--)
			{
				int n = listPrimary.SelectedItems[z].Index;
				ListViewItem i = listPrimary.Items[n];
				listPrimary.Items[n].Remove();
				n++;
				if(n>=listPrimary.Items.Count)
				{
					listPrimary.Items.Add(i);
					n--;
				}
				else
					listPrimary.Items.Insert(n,i);
				listPrimary.Items[n].Selected = true;
			}
		}
		#endregion
		#region TabSecondaryStim
		private void SecondaryStim_CheckedChanged(object sender, EventArgs e)
		{
			//Alter the fields shown to match the parameters for that stim type
			this.SS1txt.Size = new Size(100,20);
			btnSSBrowse.Visible = false;
			if(rdoSsTone.Checked == true)
			{
				SS1lbl.Visible = true;
				SS2lbl.Visible = true;
				SS3lbl.Visible = true;
				SS4lbl.Visible = true;
				SS5lbl.Visible = true;
				SS6lbl.Visible = true;
				SS1txt.Visible = true;
				SS2txt.Visible = true;
				SS3txt.Visible = true;
				SS4txt.Visible = true;
				SS5txt.Visible = true;
				SS6txt.Visible = true;
				SS1lbl.Text = "Frequency:";
				SS2lbl.Text = "Length (ms):";
				SS3lbl.Text = "Rise Time (ms):";
				SS4lbl.Text = "Fall Time (ms):";
				SS5lbl.Text = "Ear:";
				SS6lbl.Text = "Initial Level:";
				SS1txt.Text = "1000";
				SS2txt.Text = "1000";
				SS3txt.Text = "20";
				SS4txt.Text = "20";
				SS5txt.Text = "Both";
				SS6txt.Text = "60";
				SS7lbl.Visible = false;
				SS8lbl.Visible = false;
				SS7txt.Visible = false;
				SS8txt.Visible = false;
			}
			else if(rdoSsPulse.Checked == true)
			{
				SS1lbl.Visible = true;
				SS2lbl.Visible = true;
				SS3lbl.Visible = true;
				SS4lbl.Visible = true;
				SS5lbl.Visible = true;
				SS6lbl.Visible = true;
				SS7lbl.Visible = true;
				SS1txt.Visible = true;
				SS2txt.Visible = true;
				SS3txt.Visible = true;
				SS4txt.Visible = true;
				SS5txt.Visible = true;
				SS6txt.Visible = true;
				SS7txt.Visible = true;
				SS1lbl.Text = "Frequency:";
				SS2lbl.Text = "Pulse Length (ms):";
				SS3lbl.Text = "Interval (ms):";
				SS4lbl.Text = "Rise Time (ms):";
				SS5lbl.Text = "Fall Time (ms):";
				SS6lbl.Text = "Ear:";
				SS7lbl.Text = "Initial Level:";
				SS1txt.Text = "1000";
				SS2txt.Text = "300";
				SS3txt.Text = "50";
				SS4txt.Text = "20";
				SS5txt.Text = "20";
				SS6txt.Text = "Both";
				SS7txt.Text = "60";
				SS8lbl.Visible = false;
				SS8txt.Visible = false;
			}
			else if(rdoSsNbn.Checked == true)
			{
				SS1lbl.Visible = true;
				SS2lbl.Visible = true;
				SS3lbl.Visible = true;
				SS4lbl.Visible = true;
				SS5lbl.Visible = true;
				SS6lbl.Visible = true;
				SS7lbl.Visible = true;
				SS1txt.Visible = true;
				SS2txt.Visible = true;
				SS3txt.Visible = true;
				SS4txt.Visible = true;
				SS5txt.Visible = true;
				SS6txt.Visible = true;
				SS7txt.Visible = true;
				//center freq ; bw(in fraction of octave) ; length ms ; rise ms ; fall ms ; ear ; initial level (dB)
				SS1lbl.Text = "Center Frequency:";
				SS2lbl.Text = "BW (fraction of an octave):";
				SS3lbl.Text = "Length (ms):";
				SS4lbl.Text = "Rise Time (ms):";
				SS5lbl.Text = "Fall Time (ms):";
				SS6lbl.Text = "Ear:";
				SS7lbl.Text = "Initial Level:";
				SS1txt.Text = "1000";
				SS2txt.Text = "3";
				SS3txt.Text = "1000";
				SS4txt.Text = "20";
				SS5txt.Text = "20";
				SS6txt.Text = "Both";
				SS7txt.Text = "60";
				SS8lbl.Visible = false;
				SS8txt.Visible = false;

			}
			else if(rdoSsPnbn.Checked == true)
			{
				SS1lbl.Visible = true;
				SS2lbl.Visible = true;
				SS3lbl.Visible = true;
				SS4lbl.Visible = true;
				SS5lbl.Visible = true;
				SS6lbl.Visible = true;
				SS7lbl.Visible = true;
				SS8lbl.Visible = true;
				SS1txt.Visible = true;
				SS2txt.Visible = true;
				SS3txt.Visible = true;
				SS4txt.Visible = true;
				SS5txt.Visible = true;
				SS6txt.Visible = true;
				SS7txt.Visible = true;
				SS8txt.Visible = true;
				//center freq ; bw(in fraction of octave) ; length of each pulse; interval ; rise ; fall ; ear ; initial level (dB)
				SS1lbl.Text = "Center Frequency:";
				SS2lbl.Text = "BW (fraction of an octave):";
				SS3lbl.Text = "Length of Pulse(ms):";
				SS4lbl.Text = "Interval:";
				SS5lbl.Text = "Rise Time (ms):";
				SS6lbl.Text = "Fall Time (ms):";
				SS7lbl.Text = "Ear:";
				SS8lbl.Text = "Initial Level:";
				SS1txt.Text = "1000";
				SS2txt.Text = "3";
				SS3txt.Text = "300";
				SS4txt.Text = "50";
				SS5txt.Text = "20";
				SS6txt.Text = "20";
				SS7txt.Text = "Both";
				SS8txt.Text = "60";
			}
			else if(rdoSsWav.Checked==true)
			{
				SS1lbl.Visible = true;
				SS2lbl.Visible = true;
				SS3lbl.Visible = true;
				SS4lbl.Visible = true;
				SS6lbl.Visible = true;
				SS7lbl.Visible = true;
				SS1txt.Visible = true;
				SS2txt.Visible = true;
				SS3txt.Visible = true;
				SS4txt.Visible = true;
				SS6txt.Visible = true;
				SS7txt.Visible = true;
				this.SS1txt.Size = new Size(300,20);
				btnSSBrowse.Visible = true;
				SS1lbl.Text = @"File:";
				SS2lbl.Text = "Category:";
				SS3lbl.Text = "Response:";
				SS4lbl.Text = "Initial Level:";
				SS6lbl.Text = "Ear:";
				SS7lbl.Text = "Amplitude:";
				SS1txt.Text = "";
				SS2txt.Text = "Adult";
				SS3txt.Text = "1";
				SS4txt.Text = "60";
				SS6txt.Text = "Both";
				SS7txt.Text = "None";

				SS5lbl.Visible = false;
				SS5txt.Visible = false;
				SS8lbl.Visible = false;
				SS8txt.Visible = false;
			}

		}

		private void btnSSBrowse_Click(object sender, System.EventArgs e)
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Wav file (*.wav)|*.wav";
			dlg.Filter += "|All files|*.*";
			dlg.Multiselect = true;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				SS1txt.Text = string.Empty;
				for(int x=0;x<dlg.FileNames.Length;x++)
				{
					SS1txt.Text += dlg.FileNames[x];
					SS1txt.Text+=";";
				}
				int lastIn = SS1txt.Text.LastIndexOf(";");
				if(lastIn >0) SS1txt.Text = SS1txt.Text.Remove(lastIn,1);
				SS1txt.Tag = dlg.FileNames;
			}
		}

		private void btnSSAdd_Click(object sender, System.EventArgs e)
		{
			//Add the data in the text boxes to the list
			//What type of stim is it?
			ListViewItem i = GetSecondaryListItem(true);
			if(i.Text.Length>0)
				listSecondary.Items.Add(i);
		
		}

		private void btnSSRemove_Click(object sender, System.EventArgs e)
		{
			if(listSecondary.SelectedItems.Count<=0)
				return;
			while(listSecondary.SelectedItems.Count>0)
			{
				listSecondary.Items.Remove(listSecondary.SelectedItems[0]);
			}
		}
		private void btnSSUpdate_Click(object sender, System.EventArgs e)
		{
			if(listSecondary.SelectedItems.Count<=0)
				return;
			ListViewItem i = GetSecondaryListItem(false);
			if(i.Text.Length>0)
			{
				int n = listSecondary.SelectedIndices[0];
				listSecondary.Items.RemoveAt(n);
				listSecondary.Items.Insert(n,i);
			}
		}
		private ListViewItem GetSecondaryListItem(bool bNew)
		{
			ListViewItem i = new ListViewItem();
			i.Text = string.Empty;
			if(rdoSsTone.Checked==true)
			{
				i.Text = string.Format("Stimuli.Secondary:tone;{0};{1};{2};{3};{4};{5}",
					SS1txt.Text,SS2txt.Text,SS3txt.Text,SS4txt.Text,SS5txt.Text,SS6txt.Text);
			}
			else if(rdoSsPulse.Checked==true)
			{
				i.Text = string.Format("Stimuli.Secondary:pulse;{0};{1};{2};{3};{4};{5};{6}",
					SS1txt.Text,SS2txt.Text,SS3txt.Text,SS4txt.Text,SS5txt.Text,SS6txt.Text,SS7txt.Text);
			}
			else if(rdoSsNbn.Checked==true)
			{
				i.Text = string.Format("Stimuli.Secondary:nbn;{0};{1};{2};{3};{4};{5};{6}",
					SS1txt.Text,SS2txt.Text,SS3txt.Text,SS4txt.Text,SS5txt.Text,SS6txt.Text,SS7txt.Text);

			}
			else if(rdoSsPnbn.Checked==true)
			{
				i.Text = string.Format("Stimuli.Secondary:pnbn;{0};{1};{2};{3};{4};{5};{6};{7}",
					SS1txt.Text,SS2txt.Text,SS3txt.Text,SS4txt.Text,SS5txt.Text,SS6txt.Text,SS7txt.Text,SS8txt.Text);

			}
			else if(rdoSsWav.Checked==true)
			{
				if(bNew==true)
				{
					string[] str = (string[]) SS1txt.Tag;
					for(int x=0;x<str.Length;x++)
					{
						i.Text = string.Format("Stimuli.Secondary:wave;{0};{1};{2};{3};{4};{5}",
							str[x],SS2txt.Text,SS3txt.Text,SS4txt.Text,SS6txt.Text,SS7txt.Text);
						listSecondary.Items.Add(i);
						i = new ListViewItem();
					}
				}
				else
				{
					i.Text = string.Format("Stimuli.Secondary:wave;{0};{1};{2};{3};{4};{5}",
						SS1txt.Text,SS2txt.Text,SS3txt.Text,SS4txt.Text,SS6txt.Text,SS7txt.Text);
				}

			}
			return i;
		}
		private void listSecondary_Click(object sender, EventArgs e)
		{
			if(listSecondary.SelectedItems.Count<=0)
				return;
			string str = listSecondary.SelectedItems[0].Text;
			string[] arrIn;
			string[] arr = new string[8];
			char[] szSeps = {':',';'};
			arrIn = str.Split(szSeps,10);
			string strType = arrIn[1].ToLower().Trim();
			//commonly used
			SS1txt.Text = arrIn[2].Trim();
			SS2txt.Text = arrIn[3].Trim();
			SS3txt.Text = arrIn[4].Trim();
			SS4txt.Text = arrIn[5].Trim();
			SS5txt.Text = arrIn[6].Trim();
			SS6txt.Text = arrIn[7].Trim();
			switch(strType)
			{
				case "tone":
					rdoSsTone.Checked = true;
					break;
				case "pulse":
					rdoSsPulse.Checked = true;
					SS7txt.Text = arrIn[8].Trim();
					break;
				case "nbn":
					rdoSsNbn.Checked = true;
					SS7txt.Text = arrIn[8].Trim();
					break;
				case "pnbn":
					rdoSsPnbn.Checked = true;
					SS7txt.Text = arrIn[8].Trim();
					SS8txt.Text = arrIn[9].Trim();
					break;
				case "wave":
					//have to handle differently because of the c: factor
					//find first colon
					int n = str.IndexOf(":",0);
					str = str.Substring(n);//remove "PrimaryStim:"
					char[] sz = {';'};//now, split on ; in order to keep c:\filename together
					arrIn = str.Split(sz,7);
					rdoSsWav.Checked = true;
					if(main.def!=null)
					{
						//for old style that used StimDirectory parameter
						if(main.def.strStimDirectory.Length>0)
							SS1txt.Text = main.def.strStimDirectory.Trim() + arrIn[1].Trim();
						else
							SS1txt.Text = arrIn[1].Trim();
					}
					else
						SS1txt.Text = arrIn[1].Trim();
					SS2txt.Text = arrIn[2].Trim();
					SS3txt.Text = arrIn[3].Trim();
					SS4txt.Text = arrIn[4].Trim();
					SS6txt.Text = arrIn[5].Trim();
					SS7txt.Text = arrIn[6].Trim();
					break;
			}
		}
		private void btnUpSecondary_Click(object sender, System.EventArgs e)
		{
			if(listSecondary.SelectedItems.Count<=0)
				return;
			for(int z=0;z<listSecondary.SelectedItems.Count;z++)
			{
				int n = listSecondary.SelectedItems[z].Index;
				ListViewItem i = listSecondary.Items[n];
				listSecondary.Items[n].Remove();
				n--;
				if(n<0)
					n = 0;
				listSecondary.Items.Insert(n,i);
				listSecondary.Items[n].Selected = true;
			}
		}

		private void btnDownSecondary_Click(object sender, System.EventArgs e)
		{
			if(listSecondary.SelectedItems.Count<=0)
				return;
			for(int z=listSecondary.SelectedItems.Count-1;z>=0;z--)
			{
				int n = listSecondary.SelectedItems[z].Index;
				ListViewItem i = listSecondary.Items[n];
				listSecondary.Items[n].Remove();
				n++;
				if(n>=listSecondary.Items.Count)
				{
					listSecondary.Items.Add(i);
					n--;
				}
				else
					listSecondary.Items.Insert(n,i);
				listSecondary.Items[n].Selected = true;
			}
		}
		#endregion
		#region TabButtons
		private void btnBtnBrowse_Click(object sender, System.EventArgs e)
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Bitmap (*.bmp)|*.bmp";
			dlg.Multiselect = false;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				BtnPic.Text = dlg.FileName;
			}
		}

		private void BtnAdd_Click(object sender, System.EventArgs e)
		{
			//BUTTON: XSIZE ; YSIZE ; XLOC ; YLOC ;FontSize; Response Category ; TEXT ; Picture file (full path)
			ListViewItem i = new ListViewItem();
			i.Text = string.Format("Button:{0};{1};{2};{3};{4};{5};{6};\"{7}\"",
				BtnXSize.Text,BtnYSize.Text,BtnXLoc.Text,BtnYLoc.Text,
				BtnFontSize.Text,BtnResponseCat.Text,BtnText.Text,BtnPic.Text);
			listButtons.Items.Add(i);

		}

		private void BtnUpdate_Click(object sender, System.EventArgs e)
		{
			if(listButtons.SelectedItems.Count<=0)
				return;
			ListViewItem i = new ListViewItem();
			i.Text = string.Format("Button:{0};{1};{2};{3};{4};{5};{6};\"{7}\"",
				BtnXSize.Text,BtnYSize.Text,BtnXLoc.Text,BtnYLoc.Text,
				BtnFontSize.Text,BtnResponseCat.Text,BtnText.Text,BtnPic.Text);			
			if(i.Text.Length>0)
			{
				int n = listButtons.SelectedIndices[0];
				listButtons.Items.RemoveAt(n);
				listButtons.Items.Insert(n,i);
			}
		}

		private void BtnRemove_Click(object sender, System.EventArgs e)
		{
			if(listButtons.SelectedItems.Count<=0)
				return;
			while(listButtons.SelectedItems.Count>0)
			{
				listButtons.Items.Remove(listButtons.SelectedItems[0]);
			}
		}
		private void listButtons_Click(object sender, EventArgs e)
		{
			if(listButtons.SelectedItems.Count<=0)
				return;
			string str = listButtons.SelectedItems[0].Text;
			string[] arrIn;
			string[] arr = new string[8];
			int n = str.IndexOf(":",0);
			str = str.Substring(n+1);//remove "Button:"
			char[] sz = {';'};//now, split on ; in order to keep c:\filename together
			arrIn = str.Split(sz,8);
			BtnXSize.Text = arrIn[0];
			BtnYSize.Text = arrIn[1];
			BtnXLoc.Text = arrIn[2];
			BtnYLoc.Text = arrIn[3];
			BtnFontSize.Text = arrIn[4];
			BtnResponseCat.Text = arrIn[5];
			BtnText.Text = arrIn[6];
			BtnPic.Text = arrIn[7].Replace("\"","");
		}
		#endregion
		#region TabFeedback
		private void btnFeedbackAdd_Click(object sender, System.EventArgs e)
		{
			OpenFileDialog dlg = new OpenFileDialog();
			dlg.Filter = "Text files (*.txt)|*.txt";
			dlg.Filter += "|All files|*.*";
			dlg.Multiselect = true;
			if(dlg.ShowDialog()==DialogResult.OK)
			{
				for(int x=0;x<dlg.FileNames.Length;x++)
				{
					ListViewItem i = new ListViewItem();
					i.Text = dlg.FileNames[x];
					listFeedback.Items.Add(i);
				}
			}
		}

		private void btnFeedbackRemove_Click(object sender, System.EventArgs e)
		{
			if(listFeedback.SelectedItems.Count<=0)
				return;
			while(listFeedback.SelectedItems.Count>0)
			{
				listFeedback.Items.Remove(listFeedback.SelectedItems[0]);
			}
		}
		private void btnUpFeedback_Click(object sender, System.EventArgs e)
		{
			if(listFeedback.SelectedItems.Count<=0)
				return;
			for(int z=0;z<listFeedback.SelectedItems.Count;z++)
			{
				int n = listFeedback.SelectedItems[z].Index;
				ListViewItem i = listFeedback.Items[n];
				listFeedback.Items[n].Remove();
				n--;
				if(n<0)
					n = 0;
				listFeedback.Items.Insert(n,i);
				listFeedback.Items[n].Selected = true;
			}
		}

		private void btnDownFeedback_Click(object sender, System.EventArgs e)
		{
			if(listFeedback.SelectedItems.Count<=0)
				return;
			for(int z=listFeedback.SelectedItems.Count-1;z>=0;z--)
			{
				int n = listFeedback.SelectedItems[z].Index;
				ListViewItem i = listFeedback.Items[n];
				listFeedback.Items[n].Remove();
				n++;
				if(n>=listFeedback.Items.Count)
				{
					listFeedback.Items.Add(i);
					n--;
				}
				else
					listFeedback.Items.Insert(n,i);
				listFeedback.Items[n].Selected = true;
			}
		}
		#endregion TabFeedback
		#region TabResults
		/*
		 * For adaptive paradigms, any order of the arguments in the Stimuli.Primary and/or Stimuli.Secondary parameters may be used.

ear
method
stimcat
altcat
primarystim
secondarystim

Results: ear ; stimcat

	For fixed paradigms, two types of analysis are available: 
perf   performance (% correct)
freq   frequency (# correct/selected)

The type of analysis must be the first paradigm listed.  Then, any order of the parameters may be used. When ‘freq’ is specified, the parameters must be followed by the term ‘response’.  

Results: perf ; ear ; primarystim

Results: freq ; stimcat ; response
*/
		private void tabChanged(object sender, EventArgs e)
		{
			if(Adaptive.Text == "True")
			{
				this.ResFreq.Enabled = false;
				this.ResPerf.Enabled = false;
			}
			else
			{
				this.ResFreq.Enabled = true;
				this.ResPerf.Enabled = true;
			}

		}
		private void ResPerf_CheckedChanged(object sender, EventArgs e)
		{
			bool bNotThere = false;
			if(txtResults.Text.IndexOf("freq")<0&&txtResults.Text.IndexOf("perf")<0)
				bNotThere = true;
			if(ResPerf.Checked == true)
			{
				if(bNotThere==true)
					txtResults.Text = "perf;"+txtResults.Text;
				else
					txtResults.Text = txtResults.Text.Replace("freq;","perf;");
			}
			else
			{
				if(bNotThere==true)
					txtResults.Text = "freq;"+txtResults.Text;
				else
					txtResults.Text = txtResults.Text.Replace("perf;","freq;");
			}
		}

		private void ResFreq_CheckedChanged(object sender, EventArgs e)
		{
			if(ResFreq.Checked == true)
				txtResults.Text = txtResults.Text.Replace("perf;","freq;");
			else
				txtResults.Text = txtResults.Text.Replace("freq;","perf;");

		}

		private void ResEar_CheckedChanged(object sender, EventArgs e)
		{
			if(ResEar.Checked == true)
				txtResults.Text = txtResults.Text+="ear;";
			else
				txtResults.Text = txtResults.Text.Replace("ear;","");

		}

		private void ResMethod_CheckedChanged(object sender, EventArgs e)
		{
			if(ResMethod.Checked == true)
				txtResults.Text = txtResults.Text+="method;";
			else
				txtResults.Text = txtResults.Text.Replace("method;","");
		}

		private void ResPrimary_CheckedChanged(object sender, EventArgs e)
		{
			if(ResPrimary.Checked == true)
				txtResults.Text = txtResults.Text+="primarystim;";
			else
				txtResults.Text = txtResults.Text.Replace("primarystim;","");
		}

		private void ResSecondary_CheckedChanged(object sender, EventArgs e)
		{
			if(ResSecondary.Checked == true)
				txtResults.Text = txtResults.Text+="secondarystim;";
			else
				txtResults.Text = txtResults.Text.Replace("secondarystim;","");
		}

		private void ResStimCat_CheckedChanged(object sender, EventArgs e)
		{
			if(ResStimCat.Checked == true)
				txtResults.Text = txtResults.Text+="stimcat;";
			else
				txtResults.Text = txtResults.Text.Replace("stimcat;","");
		}

		private void ResAltCat_CheckedChanged(object sender, EventArgs e)
		{
			if(ResAltCat.Checked == true)
				txtResults.Text = txtResults.Text+="altcat;";
			else
				txtResults.Text = txtResults.Text.Replace("altcat;","");
		}


		#endregion
		#region Categorical Loudness
		private void chkCL_CheckedChanged(object sender, System.EventArgs e)
		{
			if(chkCL.Checked==true)
			{
				this.tabControl1.TabPages.Remove(this.tabConstants);
				this.tabControl1.TabPages.Remove(this.tabAdaptive);
				this.tabControl1.TabPages.Remove(this.tabSecondary);
				this.tabControl1.TabPages.Remove(this.tabButtons);
				this.tabControl1.TabPages.Remove(this.tabFeedback);
				this.tabControl1.TabPages.Remove(this.tabResults);
				this.tabControl1.TabPages.Remove(this.tabCL);
				this.tabControl1.TabPages.Remove(this.tabPrimary);
				this.tabControl1.TabPages.Add(this.tabCL);
				this.tabControl1.TabPages.Add(this.tabPrimary);
			}
			else
			{
				this.tabControl1.TabPages.Remove(this.tabCL);
				this.tabControl1.TabPages.Remove(this.tabPrimary);
				this.tabControl1.TabPages.Add(this.tabConstants);
				this.tabControl1.TabPages.Add(this.tabAdaptive);
				this.tabControl1.TabPages.Add(this.tabPrimary);
				this.tabControl1.TabPages.Add(this.tabSecondary);
				this.tabControl1.TabPages.Add(this.tabButtons);
				this.tabControl1.TabPages.Add(this.tabFeedback);
				this.tabControl1.TabPages.Add(this.tabResults);
				this.tabControl1.TabPages.Add(this.tabCL);
			}
		
		}

		#endregion
		private void LinkClicked(object sender, System.Windows.Forms.LinkLabelLinkClickedEventArgs e)
		{
			if(main.Manual.Length<=0)
				SetManual();
			try
			{
				object oMissing = System.Reflection.Missing.Value;
				LinkLabel l = (LinkLabel) sender;
				string str = l.Text;
				if(str=="Help")
					str = l.Name;
				str = str.Replace(" ","");
				str = str.Replace(":","");
				str = str.Replace("(","");
				str = str.Replace(")","");
				str = str.Replace("'","");
				str = str.Replace("-","");
				str = str.Replace("#","");
				str = str.Replace(",","");
				/*oWord = new Word.Application();
				oWord.Visible = true;
				object oFile = main.Manual;
				object oReadOnly = true;
				oDoc = oWord.Documents.Open(ref oFile,ref oMissing,ref oReadOnly,ref oMissing,
					ref oMissing,ref oMissing,ref oMissing,
					ref oMissing,ref oMissing,ref oMissing,
					ref oMissing,ref oMissing,ref oMissing,
					ref oMissing,ref oMissing,ref oMissing);
				object oBookmarkName = str;
				Word.Range rng = oDoc.Bookmarks.get_Item(
					ref oBookmarkName).Range;
				rng.Select();*/
			}
			catch(Exception err)
			{
				MessageBox.Show(err.Message);
			}
		}

		#region Making stuff appear and disappear
		private void CatchTrials_SelectedValueChanged(object sender, EventArgs e)
		{
			SetCatch();
		}
		private void SetCatch()
		{
			if(CatchTrials.Text=="True")
			{
				this.BacktoBackCatch.Enabled = true;
				this.CatchLength.Enabled = true;
				this.CatchFreq.Enabled = true;
			}
			else
			{
				this.BacktoBackCatch.Enabled = false;
				this.CatchLength.Enabled = false;
				this.CatchFreq.Enabled = false;
			}
		}
		private void Interval_SelectedValueChanged(object sender, EventArgs e)
		{
			SetInterval();
		}
		private void SetInterval()
		{
			if(Interval.Text=="True")
			{
				IntervalLength.Enabled = true;
				IntervalSpace.Enabled = true;
			}
			else
			{
				IntervalLength.Enabled = false;
				IntervalSpace.Enabled = false;
			}
		}
		private void Adaptive_SelectedValueChanged(object sender, EventArgs e)
		{
			SetAdaptive();
		}
		private void SetAdaptive()
		{
			if(Adaptive.Text!="None")
			{
				this.Method.Enabled = true;
				this.OnCorrect.Enabled = true;
				this.PrimaryStep.Enabled = true;
				this.SecondaryStep.Enabled = true;
				this.StopMode.Enabled = true;
				this.StandardError.Enabled = true;
				this.NumOfReversals.Enabled = true;
				this.NumOfStopReversals.Enabled = true;
			}
			else
			{
				this.Method.Enabled = false;
				this.OnCorrect.Enabled = false;
				this.PrimaryStep.Enabled = false;
				this.SecondaryStep.Enabled = false;
				this.StopMode.Enabled = false;
				this.StandardError.Enabled = false;
				this.NumOfReversals.Enabled = false;
				this.NumOfStopReversals.Enabled = false;
			}
		}
		#endregion

		private void btnComplexAdd_Click(object sender, System.EventArgs e)
		{
			ComplexStim cs = new ComplexStim();
			
			ArrayList list = new ArrayList();
			list.Add("Stimuli.Primary");
			list.Add("Stimuli.Secondary");
			string strType = GetField("Primary or Secondary?",1,list);
			list.Clear();
			cs.nTotalLength = int.Parse( GetField("Total Stim Length (ms):",0,null) );
			cs.nNumberOfStims = int.Parse( GetField("Number of Component Stims:",0,null) );
			for(int i=0;i<cs.nNumberOfStims;i++)
			{
				Stim s = new Stim();
				list.Add("Tone");
				list.Add("Pulse");
				list.Add("NBN");
				list.Add("NBP");
				s.strType = GetField("Stim " + i.ToString() + " type:",1,list);
				list.Clear();
				if(s.strType=="tone")
				{
					s.nFreq = int.Parse( GetField("Stim " + i.ToString() + " Frequency:",0,null) );
					s.nInitialPhase = int.Parse( GetField("Stim " + i.ToString() + " Phase (degrees):",0,null) );
				}
				else if(s.strType=="pulse")
				{
					s.nFreq = int.Parse( GetField("Stim " + i.ToString() + " Frequency:",0,null) );
					s.nInitialPhase = int.Parse( GetField("Stim " + i.ToString() + " Phase (degrees):",0,null) );
					s.nLength = int.Parse( GetField("Stim " + i.ToString() + " Pulse Length (ms):",0,null) );
					s.nInterval = int.Parse( GetField("Stim " + i.ToString() + " Interval Length (ms):",0,null) );
				}
				else if(s.strType=="nbn")
				{
					s.nFreq = int.Parse( GetField("Stim " + i.ToString() + " Center Frequency:",0,null) );
					s.nOctave = int.Parse( GetField("Stim " + i.ToString() + " Bandwidth (fraction of an octave):",0,null) );
				}
				else if(s.strType=="nbp")
				{
					s.nFreq = int.Parse( GetField("Stim " + i.ToString() + " Center Frequency:",0,null) );
					s.nOctave = int.Parse( GetField("Stim " + i.ToString() + " Bandwidth (fraction of an octave):",0,null) );
					s.nLength = int.Parse( GetField("Stim " + i.ToString() + " Pulse Length (ms):",0,null) );
					s.nInterval = int.Parse( GetField("Stim " + i.ToString() + " Interval Length (ms):",0,null) );
				}
				s.nRise = int.Parse( GetField("Stim " + i.ToString() + " Rise Time (ms):",0,null) );
				s.nFall = int.Parse( GetField("Stim " + i.ToString() + " Fall Time (ms):",0,null) );
				s.nOrigin = int.Parse( GetField("Stim " + i.ToString() + " Initial Level (dB):",0,null) );
				s.nStart = int.Parse( GetField("Stim " + i.ToString() + " Start Time (ms):",0,null) );
				s.nStop = int.Parse( GetField("Stim " + i.ToString() + " Stop Time (ms):",0,null) );
				list.Add("Both");
				list.Add("Left");
				list.Add("Right");
				s.strEar = GetField("Stim " + i.ToString() + " Ear:",1,list);
				list.Clear();
				list.Add("Yes");
				list.Add("No");
				string strTemp = GetField("Stim " + i.ToString() + ": Adapt this Stim?:",1,list);
				if(strTemp=="yes")
					s.bAdapt = true;
				else
					s.bAdapt = false;
				list.Clear();
				s.bIsComplexMember = true;
				cs.listStims.Add(s);
			}
			DisplayComplex(strType,cs);
		}
		private string GetField(string str, int i, ArrayList l)
		{
			ComplexWizard dlg = new ComplexWizard();
			dlg.lbl.Text = str;
			if(i==0)
			{
				dlg.cmb.Visible = false;
				dlg.txt.Focus();
			}
			else
			{
				dlg.txt.Visible = false;
				foreach(string s in l)
				{ 
					dlg.cmb.Items.Add(s);
				}
			}
			dlg.ShowDialog();
			if(dlg.DialogResult==DialogResult.Cancel)
				return null;
			else
			{
				if(i==0)
					return dlg.txt.Text.ToLower();
				else
					return dlg.cmb.Text.ToLower();
			}
		}

		private void DisplayComplex(string Type, ComplexStim cs)
		{
			/**
			 *  Stimuli.Primary:complex;2000;3
				Stimuli.Primary:tone;500;1000;20;20;both;40;90;0;2000;1
				Stimuli.Primary:tone;2000;1000;20;20;both;40;180;1000;2000;1
				Stimuli.Primary:pulse;1000;300;50;20;20;Both;40;90;0;1000;0
			**/
			TreeNode i = new TreeNode();
			i.Text = string.Format("{0}:complex;{1};{2}",
				Type,cs.nTotalLength,cs.nNumberOfStims);
			foreach(Stim s in cs.listStims)
			{
				TreeNode n = new TreeNode();
				int Adapt = 0;
				if(s.bAdapt==true)
					Adapt = 1;
				if(s.strType=="tone")
				{
					n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11}",
						Type,s.strType,s.nFreq,s.nLength,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nInitialPhase,s.nStart,s.nStop,Adapt);
				}
				else if(s.strType=="pulse")
				{
					n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11};{12}",
						Type,s.strType,s.nFreq,s.nLength,s.nInterval,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nInitialPhase,s.nStart,s.nStop,Adapt);
				}
				else if(s.strType=="nbn")
				{
					/*n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11};{12}",
						Type,s.strType,s.nFreq,s.nOctave,s.nLength,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nPhase,s.nStart,s.nStop,Adapt);*/
					n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11}",
						Type,s.strType,s.nFreq,s.nOctave,s.nLength,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nStart,s.nStop,Adapt);
				}
				else if(s.strType=="nbp")
				{
					/*n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11};{12};{13}",
						Type,s.strType,s.nFreq,s.nOctave,s.nLength,s.nInterval,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nPhase,s.nStart,s.nStop,Adapt);*/
					n.Text = string.Format("     {0}:{1};{2};{3};{4};{5};{6};{7};{8};{9};{10};{11};{12}",
						Type,s.strType,s.nFreq,s.nOctave,s.nLength,s.nInterval,s.nRise,s.nFall,s.strEar,
						s.nOrigin,s.nStart,s.nStop,Adapt);
				}
				i.Nodes.Add(n);
			}
			treeComplex.Nodes.Add(i);
		}

		private void btnComplexRemove_Click(object sender, System.EventArgs e)
		{
			if(treeComplex.SelectedNode==null)
				return;
			TreeNode n = treeComplex.SelectedNode;
			while(n.Parent!=null)
			{
				n = n.Parent;
			}
			treeComplex.Nodes.Remove(n);
		}

		private void btnPairedAdd_Click(object sender, System.EventArgs e)
		{
			ListViewItem i = GetPairedListItem(true);
		}
		private ListViewItem GetPairedListItem(bool bNew)
		{
			ListViewItem i = new ListViewItem();
			i.Text = string.Empty;
			if(rbPairedWave.Checked)
			{
				if(bNew)
				{
					if(txtPairedFolder.Text.Length>0)
					{
						i.Text = string.Format("Stimuli.Paired:wave;{0};{1};{2};{3};{4};{5}",
							txtPairedFolder.Text,txtPaired1.Text,txtPaired2.Text,txtPaired3.Text,txtPaired4.Text,cmbAmpType.Text);
						listPaired.Items.Add(i);
					}
				}
				else
					i.Text=string.Format("Stimuli.Paired:wave;{0};{1};{2};{3};{4};{5}",
						txtPairedFolder.Text,txtPaired1.Text,txtPaired2.Text,txtPaired3.Text,txtPaired4.Text,cmbAmpType.Text);
			}//for Tone
			
			return i;
		}

		private void btnPairedFolder_Click(object sender, System.EventArgs e)
		{
			FolderBrowserDialog fbd = new FolderBrowserDialog();
			if(fbd.ShowDialog()==DialogResult.OK)
			{
				txtPairedFolder.Text = fbd.SelectedPath+"\\";					
			}
		}

		private void btnPairedUpdate_Click(object sender, System.EventArgs e)
		{
			if(listPaired.SelectedItems.Count<=0)
				return;
			ListViewItem i = GetPairedListItem(false);
			if(i.Text.Length>0)
			{
				int n = listPaired.SelectedIndices[0];
				listPaired.Items.RemoveAt(n);
				listPaired.Items.Insert(n,i);
			}
		}

		private void btnPairedRemove_Click(object sender, System.EventArgs e)
		{
			if(listPaired.SelectedItems.Count<=0)
				return;
			while(listPaired.SelectedItems.Count>0)
			{	
				int n = listPaired.SelectedIndices[0];
				listPaired.Items.RemoveAt(n);
			}
		}

		private void listPaired_SelectedIndexChanged(object sender, System.EventArgs e)
		{
		
		}

		private void listPaired_Click(object sender, System.EventArgs e)
		{
			if(listPaired.SelectedItems.Count<=0)
				return;
			string str = listPaired.SelectedItems[0].Text;
			string[] arrIn;
			string[] arr = new string[8];
			int n = str.IndexOf(":",0);
			str = str.Substring(n);//remove "PairedStim:"

			char[] szSeps = {';'};
			arrIn = str.Split(szSeps,10);
			string strType = arrIn[0].ToLower().Trim();
			//commonly used
			txtPairedFolder.Text = arrIn[1].Trim();
			txtPaired1.Text = arrIn[2].Trim();
			txtPaired2.Text= arrIn[3].Trim();
			txtPaired3.Text = arrIn[4].Trim();
			txtPaired4.Text = arrIn[5].Trim();
			cmbAmpType.Text = arrIn[6].Trim();
			
			switch(strType)
			{
				
				case "wave":
					rbPairedWave.Checked = true;
					break;
			}
		}

		#region "Paired Stimuli"
		
		private void DisplayPairedControls(object sender, System.EventArgs e)
		{
			DisplayPairedControls();
		}

		private void textBox4_TextChanged(object sender, System.EventArgs e)
		{
		
		}

		private void txtFeedY_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e)
		{			
			if (!(char.IsNumber(e.KeyChar) || e.KeyChar.Equals('\b'))) { 
			TextBox tb = (TextBox)sender;
			tb.Text="";
			}
		}

		private void DefEditor_Load(object sender, System.EventArgs e)
		{
		
		}

		private void linkLabel8_LinkClicked(object sender, System.Windows.Forms.LinkLabelLinkClickedEventArgs e)
		{
		
		}
	
		private void DisplayPairedControls()
		{
			
			 if(rbPairedWave.Checked)
			{
				lblPaired1.Text="Category:";
				lblPaired2.Text="Response:";
				lblPaired3.Text="Level:";
				lblPaired4.Text="Ear:";
			}
			/*
			else if(rbPairedPulsedNBNoise.Checked)
			{
				lblPaired1.Text="Center Frequency:";
				lblPaired2.Text="BW(Fraction of Octave):";
				lblPaired3.Text="Length of Pulse[ms]:";
				lblPaired4.Text="Interval:";
				lblPaired5.Text="Rise Time[ms]:";
				lblPaired6.Text="Fall Time[ms]:";txtPaired6.Visible=true;
				lblPaired7.Text="Ear:";txtPaired7.Visible=true;
				lblPaired8.Text="Initial Level:";txtPaired8.Visible=true;
			}
			*/
		}
		
		
		#endregion

		
	}

}