|
Wersja 2, 1.1 KB
(wprowadzona przez dorota, 17 years temu)
|
|
|
| Line | |
|---|
| 1 | using System;
|
|---|
| 2 | using System.Collections.Generic;
|
|---|
| 3 | using System.ComponentModel;
|
|---|
| 4 | using System.Data;
|
|---|
| 5 | using System.Drawing;
|
|---|
| 6 | using System.Text;
|
|---|
| 7 | using System.Windows.Forms;
|
|---|
| 8 |
|
|---|
| 9 | namespace Baza_Reklam
|
|---|
| 10 | {
|
|---|
| 11 | public partial class ExportOptions : Form
|
|---|
| 12 | {
|
|---|
| 13 | public ExportOptions()
|
|---|
| 14 | {
|
|---|
| 15 | InitializeComponent();
|
|---|
| 16 | }
|
|---|
| 17 |
|
|---|
| 18 | public ExportOptions(List<string> availableFields)
|
|---|
| 19 | {
|
|---|
| 20 | InitializeComponent();
|
|---|
| 21 |
|
|---|
| 22 | foreach (string field in availableFields)
|
|---|
| 23 | chklst.Items.Add(field, true);
|
|---|
| 24 | }
|
|---|
| 25 |
|
|---|
| 26 | private void btnOK_Click(object sender, EventArgs e)
|
|---|
| 27 | {
|
|---|
| 28 | this.DialogResult = DialogResult.OK;
|
|---|
| 29 | this.Close();
|
|---|
| 30 | }
|
|---|
| 31 |
|
|---|
| 32 | private void btnCancel_Click(object sender, EventArgs e)
|
|---|
| 33 | {
|
|---|
| 34 | this.DialogResult = DialogResult.Cancel;
|
|---|
| 35 | this.Close();
|
|---|
| 36 | }
|
|---|
| 37 |
|
|---|
| 38 | public List<string> GetSelectedColumns()
|
|---|
| 39 | {
|
|---|
| 40 | List<string> lst = new List<string>();
|
|---|
| 41 | foreach (object item in chklst.CheckedItems)
|
|---|
| 42 | lst.Add(item.ToString());
|
|---|
| 43 | return lst;
|
|---|
| 44 | }
|
|---|
| 45 | }
|
|---|
| 46 | } |
|---|
Notatka: Zobacz
TracBrowser
aby uzyskać więcej informacji.