using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; namespace graphe { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void groupBox1_Enter(object sender, EventArgs e) { } private void btnExit_Click(object sender, EventArgs e) { Application.Exit(); } private void btnConn_Click(object sender, EventArgs e) { serialPort1.PortName = txtCOMPort.Text; serialPort1.BaudRate = Convert.ToInt32(txtBaudrate.Text); if (serialPort1.IsOpen) return; serialPort1.Open(); } private void btnDisConn_Click(object sender, EventArgs e) { if (serialPort1.IsOpen == false) return; serialPort1.Open(); } } }
EDIT : Ajout des balises de code (la coloration syntaxique).
Explications disponibles ICI Merci d'y penser dans tes prochains messages. |
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre questionc'est pour ça que je me suis orientée vers vous afin de trouver des solutions déjas prêtes.