delphi2007 教程

delphi2007 教程

首页 新随笔 联系 聚合 管理
  1013 Posts :: 0 Stories :: 28 Comments :: 0 Trackbacks
这个不对了,找不到控件 Delphi / Windows SDK/API
http://www.delphi2007.net/DelphiAPI/html/delphi_20061107194340283.html
在窗体中放了一个edit   和一个按钮。  
  用file-new-other里的thread   object   创建了一个新线程类(Tmy)。  
  里面写了这句代码:  
  procedure   Tmy.Execute;  
  begin  
      {   Place   thread   code   here   }  
        form1.edit.text:='ddd';     //就是这句  
   
  end;  
  这是编译时的错误  
      [Error]   Unit2.pas(35):   Undeclared   identifier:   'form1'  
      [Error]   Unit2.pas(35):   Missing   operator   or   semicolon  
      [Error]   Unit2.pas(35):   Statement   expected,   but   expression   of   type   'String'   found  
      [Fatal   Error]   Unit1.pas(7):   Could   not   compile   used   unit   'Unit2.pas'  
   
  我在Unit1中包含了unit2,  
   
  是什么原因呢??

自己解决了。

posted on 2009-04-08 09:12 delphi2007 阅读(179) 评论(0)  编辑 收藏 引用
只有注册用户登录后才能发表评论。