K
K
Unregistered / Unconfirmed
GUEST, unregistred user!
我编了一个程序有8个窗体,
主窗体在Project Options中Forms页设在Auto-create forms:列表框中,
其他7个窗体都在Available forms:列表框中.
当我不退出主程序并多次打开这7个窗体时总是出错:
Project wy.exe raised exception class
EAccessViolation with message 'Access violation at
address 00000009. Write of address 98AA870A',Process
stopped. Use Setp or Run to continue.
是不是我每次打开的窗口没有从内存中清掉造成的.
主单元程序:
program wy;
uses
Forms,
krk in 'krk.pas' {wyFormrk},
booknaem in 'booknaem.pas' {Formbook},
booklb in 'booklb.pas' {Formlb},
ksz in 'ksz.pas' {Formkh},
kdb in 'kdb.pas' {Formdb},
sm in 'sm.pas' {Formabout},
hz in 'hz.pas' {wyFormhz},
wyt in 'wyt.pas' {wyFormmain};
{$R *.RES}
begin
Application.Initialize;
Application.Title := '图书账务软件';
Application.CreateForm(TwyFormmain, wyFormmain);
Application.Run;
end.
我在程序中每个窗口都是这样打开的:
procedure TwyFormmain.N15Click(Sender: TObject);
begin
wyformhz:=Twyformhz.Create(application);
wyformhz.Show;
end;
当关闭时:
procedure TwyFormrk.SpeedButton3Click(Sender: TObject);
begin
close;
end;
procedure TwyFormmain.FormClose(Sender: TObject;
var Action: TCloseAction);
begin
wyformmain.free;
end;
请大侠帮助,我应当怎样做。
主窗体在Project Options中Forms页设在Auto-create forms:列表框中,
其他7个窗体都在Available forms:列表框中.
当我不退出主程序并多次打开这7个窗体时总是出错:
Project wy.exe raised exception class
EAccessViolation with message 'Access violation at
address 00000009. Write of address 98AA870A',Process
stopped. Use Setp or Run to continue.
是不是我每次打开的窗口没有从内存中清掉造成的.
主单元程序:
program wy;
uses
Forms,
krk in 'krk.pas' {wyFormrk},
booknaem in 'booknaem.pas' {Formbook},
booklb in 'booklb.pas' {Formlb},
ksz in 'ksz.pas' {Formkh},
kdb in 'kdb.pas' {Formdb},
sm in 'sm.pas' {Formabout},
hz in 'hz.pas' {wyFormhz},
wyt in 'wyt.pas' {wyFormmain};
{$R *.RES}
begin
Application.Initialize;
Application.Title := '图书账务软件';
Application.CreateForm(TwyFormmain, wyFormmain);
Application.Run;
end.
我在程序中每个窗口都是这样打开的:
procedure TwyFormmain.N15Click(Sender: TObject);
begin
wyformhz:=Twyformhz.Create(application);
wyformhz.Show;
end;
当关闭时:
procedure TwyFormrk.SpeedButton3Click(Sender: TObject);
begin
close;
end;
procedure TwyFormmain.FormClose(Sender: TObject;
var Action: TCloseAction);
begin
wyformmain.free;
end;
请大侠帮助,我应当怎样做。