I have a couple of problems compiling a very old application developed using C++ Builder 6 Pro. Both are in the same code block I copied above.
- E2015 Ambiguity between __fastcall IdGlobal::Sleep(unsigned int) and __stdcall Sleep(unsigned long)
- undefined exception (I mean exception in catch(Exception &exception). I hope this is caused by the error about Sleep...
So, I do not know where Sleep comes from but I think I did not want to use IdGlobal::Sleep(), how can I specify I want the 2nd Sleep?
try
{
Wp->Open = true;
Sleep(1500);
}
catch(Exception &exception)
{
TLogSysInstance->Write(_FILE("TFormMain", "PresetterInit()" + exception.Message));
if(Wp->Open != true)
{
Application->MessageBox("La porta di comunicazione selezionata per il PRESETTER non si apre.\n"
"Verificare il setup della porta di comunicazione nel file APP.INI.\n"
"E' probabile che debba essere cambiata la porta di comunicazione selezionata.",
"Attenzione: errore aprendo la porta di comunicazione", MB_OK + MB_ICONWARNING);
}
}