45 lines
1.3 KiB
C#
45 lines
1.3 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Data;
|
|
using System.Drawing;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Windows.Forms;
|
|
|
|
namespace AyaNovaQBI
|
|
{
|
|
public partial class MapSelectQBItem : Form
|
|
{
|
|
public MapSelectQBItem()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
public ComboBox SelectCombo => cbQBItems;
|
|
public string SelectedQBItemName => ((DataRowView)cbQBItems.SelectedItem).Row[0].ToString();
|
|
public string SelectedQBItemId => ((DataRowView)cbQBItems.SelectedItem).Row[1].ToString();
|
|
public DataTable QBItems { get; set; }
|
|
private void MapSelectQBItem_Load(object sender, EventArgs e)
|
|
{
|
|
cbQBItems.DataSource = QBItems;
|
|
cbQBItems.DisplayMember = "name";
|
|
cbQBItems.ValueMember = "id";
|
|
btnCancel.Text = util.AyaTranslations["Cancel"];
|
|
btnOK.Text = util.AyaTranslations["OK"];
|
|
}
|
|
|
|
private void btnCancel_Click(object sender, EventArgs e)
|
|
{
|
|
DialogResult = DialogResult.Cancel;
|
|
Close();
|
|
}
|
|
|
|
private void btnOK_Click(object sender, EventArgs e)
|
|
{
|
|
DialogResult = DialogResult.OK;
|
|
Close();
|
|
}
|
|
}
|
|
}
|