|
메시지 박스로 대용될 폼이나 컴포넌트를 하나 만드셔서 사용하시는 것이 가장
좋은 방법 같습니다.
굳이 변경하신다면 흔히 한글과 작업에 사용하는 방법 같이 타이머나 다른 쓰레드를
이용해서 갈아엎는 방법이 있긴 있지만, 깨끗한 처리는 아닌것 같습니다.
타이머하고 버튼 하나 폼에 올려놓으신 후 사용하시면 됩니다.
cuperido
//---------------------------------------------------------------------------
#include <vcl.h>
#pragma hdrstop
#include "Unit1.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner) : TForm(Owner)
{
Timer1->Interval = 10;
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Button1Click(TObject *Sender)
{
MessageDlg("Update Record?", mtConfirmation, TMsgDlgButtons() << mbYes << mbNo, 0);
}
//---------------------------------------------------------------------------
void __fastcall TForm1::Timer1Timer(TObject *Sender)
{
HWND hdHandle = FindWindow(NULL, "Confirm"), hdButtonHandle;
if(hdHandle) {
SetWindowText(hdHandle, "확인");
hdButtonHandle = FindWindowEx(hdHandle, NULL, NULL, "&Yes");
if(hdButtonHandle) SetWindowText(hdButtonHandle, "예");
hdButtonHandle = FindWindowEx(hdHandle, NULL, NULL, "&No");
if(hdButtonHandle) SetWindowText(hdButtonHandle, "아니오");
}
}
//---------------------------------------------------------------------------
초보만세 님이 쓰신 글 :
: 한글로 쓸려면 MessageBox를 사용하면 되는줄은 알고 있습니다.
:
: 하지만 MessageDlg 를 쓰고 싶은데 한글버튼캡션으로 바꿀수 있는 방법이
:
: 있나요?
:
: Consts.pas 를 재컴파일 해서 사용하면 된다고 하는데 안되네요....ㅋㅋ.
:
: 고수님들 간단한 방법이 있다면 조언을 부탁드립니다....에고고....
:
: 초보만세 ^^;;
:
:
:
:
|