protected void HyperLinkB_Click(object sender, EventArgs e) { // runjQueryCode("$('.button_contrast').switchClass('button_contrast','button_crazy','slow');$('.button_crazy').switchClass('button_crazy','button_contrast','fast');"); runjQueryCode("$('.startseite_C4A').switchClass('startseite_C4A','startseite_C4A_contrast','slow');"); runjQueryCode("$('.button_normal').switchClass('button_normal','button_contrast','slow');"); runjQueryCode("$('.button_eng_normal_eservice').switchClass('button_eng_normal_eservice','button_eng_contrast_eservice','slow');"); runjQueryCode("$('.button_eng_normal').switchClass('button_eng_normal','button_eng_contrast','slow');"); runjQueryCode("$('.button_hoch_normal').switchClass('button_hoch_normal','button_hoch_contrast','slow');"); runjQueryCode("$('.button_hoch_normal_touristen').switchClass('button_hoch_normal_touristen','button_hoch_contrast_touristen','slow');"); runjQueryCode("$('.area_header').switchClass('area_header','area_header_contrast','slow');"); IDScanner scanner = new IDScanner(); String s = scanner.scan(); HyperLinkB.Text = s; }
public async void runScanner() { IDScanner scanner = new IDScanner(); //bool scanEnable = true; int counter = 3; while (counter >= 0) { string Data = scanner.scan(); counter = counter - 1; if (Data.Contains("la")) { runjQueryCode("$('.startseite_C4A').switchClass('startseite_C4A','startseite_C4A_contrast','slow');"); runjQueryCode("$('.zeiticon').switchClass('zeiticon','zeiticon_contrast','slow');"); runjQueryCode("$('.time').switchClass('time','time_contrast','slow');"); runjQueryCode("$('.button_normal').switchClass('button_normal','button_contrast','slow');"); runjQueryCode("$('.button_eng_normal_eservice').switchClass('button_eng_normal_eservice','button_eng_contrast_eservice','slow');"); runjQueryCode("$('.button_eng_normal').switchClass('button_eng_normal','button_eng_contrast','slow');"); runjQueryCode("$('.button_hoch_normal').switchClass('button_hoch_normal','button_hoch_contrast','slow');"); runjQueryCode("$('.button_hoch_normal_touristen').switchClass('button_hoch_normal_touristen','button_hoch_contrast_touristen','slow');"); runjQueryCode("$('.area_header').switchClass('area_header','area_header_contrast','slow');"); } if (Data.Contains("lo")) { runjQueryCode("$('.startseite_C4A_contrast').switchClass('startseite_C4A_contrast','startseite_C4A','slow');"); runjQueryCode("$('.zeiticon_contrast').switchClass('zeiticon_contrast','zeiticon','slow');"); runjQueryCode("$('.time_contrast').switchClass('time_contrast','time','slow');"); runjQueryCode("$('.button_contrast').switchClass('button_contrast','button_normal','slow');"); runjQueryCode("$('.button_eng_contrast_eservice').switchClass('button_eng_contrast_eservice','button_eng_normal_eservice','slow');"); runjQueryCode("$('.button_eng_contrast').switchClass('button_eng_contrast','button_eng_normal','slow');"); runjQueryCode("$('.button_hoch_contrast').switchClass('button_hoch_contrast','button_hoch_normal','slow');"); runjQueryCode("$('.button_hoch_contrast_touristen').switchClass('button_hoch_contrast_touristen','button_hoch_normal_touristen','slow');"); runjQueryCode("$('.area_header_contrast').switchClass('area_header_contrast','area_header','slow');"); } System.Threading.Thread.Sleep(1000); } //await Task.Delay(1000); }
protected void startButton_Click(object sender, EventArgs e) { // Die Auskommentierten Zeilen müssen hinzugefügt werden, falls der Scanner daueraft scannen soll(leider noch nicht funktionionsfähig) . Andernfalls scannt der Scanner einmalig beim Klicken auf den Button. //new Thread((ThreadStart)delegate() //{ // for (int i = 0; i < 5; i++) // { IDScanner scanner = new IDScanner(); string Data = scanner.scan(); //this.BeginInvoke((ThreadStart)delegate() // { if (Data.Contains("la")) { //startButton.Visible = false; this.runjQueryCode("$('.startseite_C4A').switchClass('startseite_C4A','startseite_C4A_contrast','slow');"); this.runjQueryCode("$('.zeiticon').switchClass('zeiticon','zeiticon_contrast','slow');"); this.runjQueryCode("$('.time').switchClass('time','time_contrast','slow');"); this.runjQueryCode("$('.button_normal').switchClass('button_normal','button_contrast','slow');"); this.runjQueryCode("$('.button_eng_normal_eservice').switchClass('button_eng_normal_eservice','button_eng_contrast_eservice','slow');"); this.runjQueryCode("$('.button_eng_normal').switchClass('button_eng_normal','button_eng_contrast','slow');"); this.runjQueryCode("$('.button_hoch_normal').switchClass('button_hoch_normal','button_hoch_contrast','slow');"); this.runjQueryCode("$('.button_hoch_normal_touristen').switchClass('button_hoch_normal_touristen','button_hoch_contrast_touristen','slow');"); this.runjQueryCode("$('.area_header').switchClass('area_header','area_header_contrast','slow');"); } if (Data.Contains("lo")) { //startButton.Visible = false; this.runjQueryCode("$('.startseite_C4A_contrast').switchClass('startseite_C4A_contrast','startseite_C4A','slow');"); this.runjQueryCode("$('.zeiticon_contrast').switchClass('zeiticon_contrast','zeiticon','slow');"); this.runjQueryCode("$('.time_contrast').switchClass('time_contrast','time','slow');"); this.runjQueryCode("$('.button_contrast').switchClass('button_contrast','button_normal','slow');"); this.runjQueryCode("$('.button_eng_contrast_eservice').switchClass('button_eng_contrast_eservice','button_eng_normal_eservice','slow');"); this.runjQueryCode("$('.button_eng_contrast').switchClass('button_eng_contrast','button_eng_normal','slow');"); this.runjQueryCode("$('.button_hoch_contrast').switchClass('button_hoch_contrast','button_hoch_normal','slow');"); this.runjQueryCode("$('.button_hoch_contrast_touristen').switchClass('button_hoch_contrast_touristen','button_hoch_normal_touristen','slow');"); this.runjQueryCode("$('.area_header_contrast').switchClass('area_header_contrast','area_header','slow');"); } //}); // } // }).Start(); }
protected void HyperLinkC_Click(object sender, EventArgs e) { IDScanner scanner = new IDScanner(); string Data = scanner.scan(); if(Data.Contains("la")) { runjQueryCode("$('.startseite_C4A').switchClass('startseite_C4A','startseite_C4A_contrast','slow');"); runjQueryCode("$('.zeiticon').switchClass('zeiticon','zeiticon_contrast','slow');"); runjQueryCode("$('.time').switchClass('time','time_contrast','slow');"); runjQueryCode("$('.button_normal').switchClass('button_normal','button_contrast','slow');"); runjQueryCode("$('.button_eng_normal_eservice').switchClass('button_eng_normal_eservice','button_eng_contrast_eservice','slow');"); runjQueryCode("$('.button_eng_normal').switchClass('button_eng_normal','button_eng_contrast','slow');"); runjQueryCode("$('.button_hoch_normal').switchClass('button_hoch_normal','button_hoch_contrast','slow');"); runjQueryCode("$('.button_hoch_normal_touristen').switchClass('button_hoch_normal_touristen','button_hoch_contrast_touristen','slow');"); runjQueryCode("$('.area_header').switchClass('area_header','area_header_contrast','slow');"); } if (Data.Contains("lo")) { runjQueryCode("$('.startseite_C4A_contrast').switchClass('startseite_C4A_contrast','startseite_C4A','slow');"); runjQueryCode("$('.zeiticon_contrast').switchClass('zeiticon_contrast','zeiticon','slow');"); runjQueryCode("$('.time_contrast').switchClass('time_contrast','time','slow');"); runjQueryCode("$('.button_contrast').switchClass('button_contrast','button_normal','slow');"); runjQueryCode("$('.button_eng_contrast_eservice').switchClass('button_eng_contrast_eservice','button_eng_normal_eservice','slow');"); runjQueryCode("$('.button_eng_contrast').switchClass('button_eng_contrast','button_eng_normal','slow');"); runjQueryCode("$('.button_hoch_contrast').switchClass('button_hoch_contrast','button_hoch_normal','slow');"); runjQueryCode("$('.button_hoch_contrast_touristen').switchClass('button_hoch_contrast_touristen','button_hoch_normal_touristen','slow');"); runjQueryCode("$('.area_header_contrast').switchClass('area_header_contrast','area_header','slow');"); } HyperLink4.Text = Data; // runjQueryCode("$('.button_contrast').switchClass('button_contrast','button_crazy','slow');$('.button_crazy').switchClass('button_crazy','button_contrast','fast');"); // runjQueryCode("$('.startseitemvv').switchClass('startseitemvv','startseitemvv_contrast','slow');"); // runjQueryCode("$('.area_header').switchClass('area_header','area_header_contrast','slow');"); // runjQueryCode("$('.zeiticon').switchClass('zeiticon','zeiticon_contrast','slow');"); // runjQueryCode("$('.time').switchClass('time','time_contrast','slow');"); // runjQueryCode("$('.button_normal').switchClass('button_normal','button_contrast','slow');"); // runjQueryCode("$('.button_eng_normal_eservice').switchClass('button_eng_normal_eservice','button_eng_contrast_eservice','slow');"); // runjQueryCode("$('.button_eng_normal').switchClass('button_eng_normal','button_eng_contrast','slow');"); // runjQueryCode("$('.button_hoch_normal').switchClass('button_hoch_normal','button_hoch_contrast','slow');"); // runjQueryCode("$('.button_hoch_normal_touristen').switchClass('button_hoch_normal_touristen','button_hoch_contrast_touristen','slow');"); }
void startScanner() { IDScanner scanner = new IDScanner(); //bool scanEnable = true; //int counter = 3; // while (counter >= 0) //{ string Data = scanner.scan(); //counter = counter - 1; // if (Raise_scanning_detected != null) //Raise_scanning_detected(Data); }