首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > .NET >

为什么小弟我编译不了exe程序

2012-03-02 
为什么我编译不了exe程序?提示这个:[Error] Project1.dpr(5): Declaration expected but identifier Unit

为什么我编译不了exe程序?
提示这个:
[Error] Project1.dpr(5): Declaration expected but identifier 'Unit1' found
[Error] Project1.dpr(20): Undeclared identifier: 'TForm1'
我的项目代码:

Delphi(Pascal) code
program Project1;uses  Forms,windows;  Unit1 in 'Unit1.pas' {Form1};{$R *.res} const      ClassName='Tform1'; var      Handle:integer; begin  handle:=findwindow(classname,nil);    if handle<>0 then     begin    messagebox(0,'请不要重复启动!','运行',0);   exit;   end;  Application.Initialize;  Application.CreateForm(TForm1, Form1);  Application.Run;end.



[解决办法]
Delphi(Pascal) code
program Project1;uses  Forms,windows,    //这里是逗号吧!  Unit1 in 'Unit1.pas' {Form1}; 

热点排行