예제 #1
0
        private int miOldNodeIndex = -1;        // for showing different tooltips for different nodes


        private void RFIDNotification_Load(object sender, EventArgs e)
        {
            // If you have more than 1 IP Address on your PC use the two parameters' constructor instead.
            mServers[0] = new CAlienServer(7797);       // Notifications
            mServers[1] = new CAlienServer(7798);       // TagStream
            mServers[2] = new CAlienServer(7799);       // IOStream

            chlServers.Items.Add("Notify Server", false);
            chlServers.Items.Add("TagStream Server", false);
            chlServers.Items.Add("IOStream Server", false);


            mDiscoverer = new clsReaderMonitor();

            mClients = new Hashtable();
            for (int i = 0; i < 3; i++)
            {
                addServerEvents(i);
            }
            mDiscoverer.ReaderAdded += new nsAlienRFID2.clsReaderMonitor.ReaderAddedEventHandler(mDiscoverer_ReaderAdded);
        }
예제 #2
0
 private void Form1_Load(object sender, EventArgs e)
 {
     textBox_ListeningPort.GotFocus  += new System.EventHandler(OnFocusListeningPort);
     textBox_ListeningPort.LostFocus += new System.EventHandler(OnLostListeningPort);
     monitor = new clsReaderMonitor();
     monitor.ComPortsMonitoring = false;
     monitor.NetworkMonitoring  = true;
     monitor.ReaderAdded       +=
         new clsReaderMonitor.ReaderAddedEventHandler(ReaderAdded);
     monitor.ReaderRenewed +=
         new clsReaderMonitor.ReaderRenewedEventHandler(ReaderRenewed);
     monitor.ReaderRemoved +=
         new clsReaderMonitor.ReaderRemovedEventHandler(ReaderRemoved);
     reader = new clsReader();
     reader.MessageReceived += new nsAlienRFID2.clsReader.MessageReceivedEventHandler(DataReceived);
     //reader.DataReceived += new nsAlienRFID2.clsReader.DataReceivedEventHandler(DataReceived);
     list = new ArrayList();
     radioButton_Individual.Checked = true;
     button_connect.Enabled         = false;
     button_close.Enabled           = false;
     checkBox_Monitor.Enabled       = false;
 }
예제 #3
0
 private void Form1_Load(object sender, EventArgs e)
 {
     textBox_ListeningPort.GotFocus+= new System.EventHandler(OnFocusListeningPort);
     textBox_ListeningPort.LostFocus += new System.EventHandler(OnLostListeningPort);
     monitor = new clsReaderMonitor();
     monitor.ComPortsMonitoring = false;
     monitor.NetworkMonitoring = true;
     monitor.ReaderAdded +=
         new clsReaderMonitor.ReaderAddedEventHandler(ReaderAdded);
     monitor.ReaderRenewed +=
         new clsReaderMonitor.ReaderRenewedEventHandler(ReaderRenewed);
     monitor.ReaderRemoved +=
         new clsReaderMonitor.ReaderRemovedEventHandler(ReaderRemoved);
     reader = new clsReader();
     reader.MessageReceived += new nsAlienRFID2.clsReader.MessageReceivedEventHandler(DataReceived);
     reader.DataReceived += new nsAlienRFID2.clsReader.DataReceivedEventHandler(DataReceived);
     list = new ArrayList();
     radioButton_Individual.Checked = true;
     button_connect.Enabled = false;
     button_close.Enabled = false;
     checkBox_Monitor.Enabled = false;
 }
예제 #4
0
 /// <summary>
 /// Method executes when form loads
 /// </summary>
 /// <param name="sender">Object</param>
 /// <param name="e">Event Args</param>
 private void Form1_Load(object sender, EventArgs e)
 {
     textBox_ListeningPort.GotFocus+= new System.EventHandler(OnFocusListeningPort);
     textBox_ListeningPort.LostFocus += new System.EventHandler(OnLostListeningPort);
     //creates a reader monitor object
     monitor = new clsReaderMonitor();
     //sets com ports monitoring to be false
     monitor.ComPortsMonitoring = false;
     //Sets network monitoring to be true
     monitor.NetworkMonitoring = true;
     //Event handler for when reader adds
     monitor.ReaderAdded +=
         new clsReaderMonitor.ReaderAddedEventHandler(ReaderAdded);
     //Event handler for when reader renews
     monitor.ReaderRenewed +=
         new clsReaderMonitor.ReaderRenewedEventHandler(ReaderRenewed);
     //Event handler for when reader removes
     monitor.ReaderRemoved +=
         new clsReaderMonitor.ReaderRemovedEventHandler(ReaderRemoved);
     //Creates a reader object connects to rfid sensor
     reader = new clsReader();
     list = new ArrayList();
     radioButton_Individual.Checked = true;
     button_connect.Enabled = false;
     button_close.Enabled = false;
     checkBox_Monitor.Enabled = false;
 }