双击窗体出这个提示
Could not find sourcelocation to add method FormCreat."END." or INITIALIZAION no found in unit source.手动把代码写进去也也不执行,但能编译?
这是为什么?
怎么解决啊?

解决方案 »

  1.   

    看看你的代码最后面还是不是以END.结束
      

  2.   

    unit Biology_ZL_SelectTime;interfaceuses
      Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
      Dialogs, BaseDialog, StdCtrls, Buttons, cxSpinEdit, cxControls,
      cxContainer, cxEdit, cxTextEdit, cxMaskEdit, cxDropDownEdit, DB, ADODB;type
      TFrm_Biology_ZL_SelectTime = class(TFrm_Base_Dialog)
        Label1: TLabel;
        Label2: TLabel;
        Label3: TLabel;
        cxComboBox1: TcxComboBox;
        cxComboBox2: TcxComboBox;
        cxSpinEdit1: TcxSpinEdit;
        ADOQuery1: TADOQuery;
        procedure OkBtnClick(Sender: TObject);
      private
        { Private declarations }
      public
        { Public declarations }
        rcode:string;
        period:string;
        year:string
      end;var
      Frm_Biology_ZL_SelectTime: TFrm_Biology_ZL_SelectTime;implementation
    Uses Pubdata;
    {$R *.dfm}
    procedure TFrm_Biology_ZL_SelectTime.OkBtnClick(Sender: TObject);
    begin
     //inherited;
      Period:=cxComboBox1.Text;
      Rcode:=cxComboBox2.Text;
      Year:= cxSpinEdit1.Text;
    end;end.
    编译能通过,
    就是不能加事件