Hi,

Has anyone any clue why message boxes keep showing 2-3 times after clicking one of their button in Borland?
Please answer, I need help.
Thanks!

Well you posted no code.. so how are we supposed to know?

I'm sorry I thought that's usual with messageboxes ( since I remember same problem in VB ).

Here's the code:

if(SAVE->OldComb()==1){
        Application->MessageBoxA("You have an old ticket, wanna use it (OK), or buy a new one(NO)?","Old ticket",MB_YESNO);
if(Application->MessageBoxA("You have an old ticket, wanna use it (OK), or buy a new one(NO)?","Old ticket",MB_YESNO)==IDYES){
        LOAD->LoadComb();
        TicketTab=new TTicketTab(Application);
        TicketTab->ShowModal();
        MainTab->Hide();
        Input1.OldTicket(true);
}
else if(Application->MessageBoxA("You have an old ticket, wanna use it (OK), or buy a new one(NO)?","Old ticket",MB_YESNO)==IDNO) {
        Lotto1.BuyTicket();
        TicketTab=new TTicketTab(Application);
        TicketTab->ShowModal();
        MainTab->Hide();
        Input1.OldTicket(false);
        }
}                    
else if(SAVE->OldComb()==0)
{
        TicketTab=new TTicketTab(Application);
        TicketTab->ShowModal();
        MainTab->Hide();
        Input1.OldTicket(false);
}

Thanks again.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.