I am running Lazarus 2.2.2 on Windows 11 64 bit. I'm fairly experienced with Delph but I've just started Lazarus.
I am attempting to display a dialog box thus :
procedure TfmMain.btQuitClick(Sender: TObject);
VAR
button_selected : integer;
begin
button_Selected := MessageDlg('Quit Awari?','Do you wish to quit Awari?',mtConfirmation, [mbYes, mbNo], 0);
IF button_selected = mrYes THEN
application.terminate;
end;
but when the code runs the box displays with a heading "confirmation" and the text is also "Conformation"
(Screen shot attached)
Okay, I have solved it. I renamed the original main unit from 'unit1' to 'main' but forgot to changes the names in the USES clause of the main program. Oddly, this didn't cause any compile errors. Once I changed the USES clause the code now works as expected.