private void btnGetLatLon1_Click(object sender, EventArgs e) { QueryMap map = new QueryMap(int.Parse(this.cmbRegionType1.SelectedValue.ToString())); if (map.ShowDialog() == DialogResult.OK) { this.cmbRegionType1.SelectedValue = map.m_iRegionType; if (map.m_iRegionType == 1) { this.txtLon11.Text = map.Longitude1; this.txtLat11.Text = map.Latitude1; this.txtLon12.Text = map.Radius.ToString(); } else { this.txtLat11.Text = map.Latitude1; this.txtLon11.Text = map.Longitude1; this.txtLat12.Text = map.Latitude2; this.txtLon12.Text = map.Longitude2; } } }