Hello, I am new here so I hope I don't write to a bad theard...
I have a little problem... Maybe I am totally wrong, but I wanted to open Form window during run of console program.. Is it possible? If so.. what is wrong with my code?
Project:
program project1;
uses Unit1, Classes, SysUtils, FileUtil, Forms, Controls, Graphics,
Dialogs, StdCtrls, Interfaces, Crt;
begin
Write('Hello');
Readln;
Form1.Show;
end.
Unit:
unit Unit1;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls, Crt;
type
{ TForm1 }
TForm1 = class(TForm)
Press_me: TButton;
procedure Press_meClick(Sender: TObject);
private
{ private declarations }
public
{ public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.lfm}
{ TForm1 }
procedure TForm1.Press_meClick(Sender: TObject);
begin
end;
end.
When I run it, so I have EXTERNAL:SIGSEGV
include\customform.inc on line 2307
Is there something wrong or shall I use other way for opening a form window?