forked from efecanicoz/lad_configurator
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Unit8.cpp
36 lines (31 loc) · 953 Bytes
/
Unit8.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "Unit8.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm8 *Form8;
//---------------------------------------------------------------------------
__fastcall TForm8::TForm8(TComponent* Owner) : TForm(Owner)
{
selected_item = -1;
}
void __fastcall TForm8::Button1Click(TObject *Sender)
{
UnicodeString str;
if(ComboBox1->Text.SubString(0,1) != "X")
{
return;
}
str = ComboBox1->Text.SubString(2, ComboBox1->Text.Length());
this->selected_item = str.ToInt();
Close();
}
//---------------------------------------------------------------------------
void __fastcall TForm8::Button2Click(TObject *Sender)
{
this->selected_item = -1;
Close();
}
//---------------------------------------------------------------------------