private void buttonAddRoom_Click(object sender, EventArgs e) { AddGateway addGateway = new AddGateway(); if (addGateway.ShowDialog() == DialogResult.OK) { MessageBox.Show("Gateway 작성이 성공하였습니다."); RefreshGatewayList(); } }
private void buttonEditRoom_Click(object sender, EventArgs e) { if (GatewayView.SelectedRows.Count == 0) { MessageBox.Show("편집할 Gateway을 먼저 선택하십시오."); return; } GatewayInfo gatewayInfo = (GatewayInfo)GatewayView.SelectedRows[0].Tag; AddGateway editRoom = new AddGateway(); editRoom._IsEditMode = true; editRoom._GatewayId = gatewayInfo.Id; if (editRoom.ShowDialog() == DialogResult.OK) { MessageBox.Show("Gateway편집이 성공하였습니다."); RefreshGatewayList(); } }