public void llenacombo(IListStrategy modulo) { comboBox3.DataSource = modulo.GetData(); comboBox3.ValueMember = "index"; comboBox3.DisplayMember = "Descriptor"; comboBox3.Enabled = true; }
private void Area_Load(object sender, EventArgs e) { switch (entidad.ToLower()) { case "area": modulo = new AreasLista(); break; case "banco": modulo = new BancoLista(); break; case "menu": modulo = new MenuLista(); break; case "tarjeta": modulo = new TarjetaLista(); break; case "depósitos": modulo = new DepositosLista(); break; case "tickets": modulo = new TicketsLista(); break; } this.Text = entidad; FillLista(); Refresca(entidad); }
public void SetOutputFormat(OutputFormat format) { listStrategy = format switch { OutputFormat.Html => new HtmlListStrategy(), OutputFormat.Markdown => new MarkdownListStrategy(), _ => throw new ArgumentOutOfRangeException(nameof(format), format, null), }; }
public void SetOutputFormat(OutputFormat format) { switch (format) { case OutputFormat.Markdown: listStrategy = new MarkdownListStrategy(); break; case OutputFormat.Html: listStrategy = new HtmlListStrategy(); break; } }
public void SetOutputFormat(OutputFormat format) { switch (format) { case OutputFormat.Markdown: listStrategy = new MarkdownListStrategy(); break; case OutputFormat.Html: listStrategy = new HtmlListStrategy(); break; default: throw new ArgumentOutOfRangeException(nameof(format), format, null); } }
public void SetOutputFormat(OutputFormat format) { switch (format) { case OutputFormat.Markdown: listStrategy = new MarkdownListStrategy(); break; case OutputFormat.Html: listStrategy = new HtmlListStrategy(); break; default: throw new ArgumentNullException(); } }
public void SetOutputFormat(OutputFormat format) { switch (format) { case OutputFormat.Markdown: _listStrategy = new MarkdownListStrategy(); break; case OutputFormat.Html: _listStrategy = new HtmlListStrategy(); break; default: throw new ArgumentOutOfRangeException($"Format {format} not supported!"); } }