멈출수가 없다는건 for문 처리 중에 버튼과 같은 폼 상의 컴포넌트 이벤트가 발생되지 않는
정확하게는 for문이 종료되 후 이벤트가 발생되는 현상을 말씀하시는 거라면
for문 안에다가
Application->ProcessMessages();
함수를 한번 이용해보세요~
for문 종료 여부는 별도의 flag를 두면 될것같습니다~
김용은 님이 쓰신 글 :
:
: if(ComboBox1->ItemIndex == ComboBox5->ItemIndex){
: int i_firstDate = cboFirstDate->ItemIndex;
: int i_lastDate = cboLastDate->ItemIndex;
:
: for(i_firstDate; i_firstDate <= i_lastDate ; i_firstDate++){
: i_data = 0;
:
:
: if( i_firstDate < 10){
: i_openPath = i_mainPath + "0"+ i_firstDate + "\\";
: }else
: i_openPath = i_mainPath + i_firstDate + "\\";
:
: for( i_data ; i_data<=ComboBox7->ItemIndex ; i_data++){
: if(FileExists(i_openPath + i_data + ".log")){
:
: MemoRight->Lines->LoadFromFile(i_openPath + i_data + ".log");
: MemoTop->Lines->Add(MemoRight->Lines->Text);
: MemoRight->Clear();
: }
: }
: }
:
: 위와같이 원하는 데이터를 메모장에 불러온뒤,
: 보여주는 프로그램인데..
:
: 도중에 멈출수가 없네요..
:
: 멈출수 있게 할수 있는 방법이 없나요.??
|