T thygw Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-10 #1 Application.MessageBox('aaaaaaaa','aaaaaaaaaa',mb_ok); 错误提示为:mb_ok没有定义! 好久的问题了!谢谢大家
Y yhaochuan Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-10 #2 是不是这个单元没有引用 windows单元 因为MB_OK是定义在windows单元的。
Y yzhshi Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-10 #4 直接使用数字代替,mb_ok的数字是$00000000 Application.MessageBox('aaaaaaaa','aaaaaaaaaa',$00000000);
T thygw Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-10 #5 不行,出错的提示为: [Error] DCSystem.dpr(42): Incompatible types: 'TMessageButtons' and 'Integer'
A apiao Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-11 #10 在工程文件中的uses中加入froms uses Forms
L lujr Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-11 #11 我的可以,代码如下: uses Windows,Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; type TForm1 = class(TForm) Button1: TButton; procedure Button1Click(Sender: TObject); private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.DFM} procedure TForm1.Button1Click(Sender: TObject); begin application.MessageBox('aaaa','sdfds',mb_ok); end; end.
我的可以,代码如下: uses Windows,Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls; type TForm1 = class(TForm) Button1: TButton; procedure Button1Click(Sender: TObject); private { Private declarations } public { Public declarations } end; var Form1: TForm1; implementation {$R *.DFM} procedure TForm1.Button1Click(Sender: TObject); begin application.MessageBox('aaaa','sdfds',mb_ok); end; end.
远 远帆 Unregistered / Unconfirmed GUEST, unregistred user! 2002-01-11 #12 program Project1; uses Forms,windows, Unit1 in 'Unit1.pas' {Form1}; {$R *.res} begin Application.Initialize; Application.CreateForm(TForm1, Form1); application.MessageBox('aaaa','sdfds',mb_ok); Application.Run; end.
program Project1; uses Forms,windows, Unit1 in 'Unit1.pas' {Form1}; {$R *.res} begin Application.Initialize; Application.CreateForm(TForm1, Form1); application.MessageBox('aaaa','sdfds',mb_ok); Application.Run; end.