|
void __fastcall TPBCICT::LineEditKeyPress(TObject *Sender, char &Key)
{
int i,j;
TIniFile *Mcini = new TIniFile("D:\\MesMc\\Config.ini");
TStringList *Line = new TStringList;
Mcini->ReadSection("3", Line);
if(Key == VK_RETURN)
{
if(LineEdit->Text == "PA05")
{
for(i=0; i<Line->Count; i++)
{
ListBox1->Items->Add(Mcini->ReadString("3", Line->Strings[i],""));
}
}
else
ShowMessage("Not LineName");
}
}
음 예로 들어서 PA05라는 모델을 입력했을때, A라는 것을 출력하고 싶은데 현재 A,B다같이 출력됩니다.
INI파일에는
[1]
L1 = PA05
L2 = PA06
[2]
F1 = A
F2 = B
라고 되어있습니다
|