private ReportesBuscarView GetDialog() { if (view == null) { //create the view if the view does not exist view = new ReportesBuscarView(); view.Closed += new EventHandler(view_Closed); } return(view); }
void view_Closed(object sender, EventArgs e) { view = null; }