private void materialRaisedButton3_Click(object sender, EventArgs e) { inicio_sesion ini = new inicio_sesion(); ini.abrir(); this.Close(); }
private void main_provedor_Load(object sender, EventArgs e) { a = 0; b = 4; inicio_sesion inn = new inicio_sesion(); string myC = "datasource=remotemysql.com ;port=3306;username=MtcqKvJRNU;password=8cjzPjeLPp"; MySqlConnection myConn = new MySqlConnection(myC); MySqlCommand sc = new MySqlCommand("select * from MtcqKvJRNU.equipo where nom_lugar = '" + inicio_sesion.id + "';", myConn); String query = string.Format("select * from MtcqKvJRNU.equipo LIMIT {0},{1};", a, b); MySqlCommand sc2 = new MySqlCommand(query, myConn); MySqlDataReader myR; myConn.Open(); myR = sc.ExecuteReader(CommandBehavior.CloseConnection); dataGridView1.Rows.Clear(); while (myR.Read() == true) { dataGridView1.Rows.Add(myR[1], myR[2], myR[4], myR[3]); } myConn.Close(); myConn.Open(); myR = sc2.ExecuteReader(CommandBehavior.CloseConnection); dataGridView2.Rows.Clear(); while (myR.Read() == true) { dataGridView2.Rows.Add(myR[1], myR[2], myR[6], myR[8]); } actualizar_datos(); myConn.Close(); gMapControl1.DragButton = MouseButtons.Left; gMapControl1.CanDragMap = true; gMapControl1.MapProvider = GMapProviders.GoogleMap; gMapControl1.Position = new PointLatLng(LongIni, LatIni); gMapControl1.MinZoom = 0; gMapControl1.MaxZoom = 24; gMapControl1.Zoom = 16; gMapControl1.AutoScroll = true; }