form2,form3为动态创建的窗体,form3由form2一个button动态产生.form2里有一个label1,form3里有一个label1
在form3中,如果有label1.caption:='sfsdfds'没有错误,但如果是form3.label1.caption:='sfsdfsd'或form2.label1.caption:='sfsdfsd'
就有错,并有诸如此类的提示"access villation at
address 0044AF58 in module "sfaproject.ext" Read of address 00000048". 为何这样?
如何做才能可以form3.label1.caption:='sfsdfsd'或form2.label1.caption:='sfsdfsd'不会错? 在线等...
在form3中,如果有label1.caption:='sfsdfds'没有错误,但如果是form3.label1.caption:='sfsdfsd'或form2.label1.caption:='sfsdfsd'
就有错,并有诸如此类的提示"access villation at
address 0044AF58 in module "sfaproject.ext" Read of address 00000048". 为何这样?
如何做才能可以form3.label1.caption:='sfsdfsd'或form2.label1.caption:='sfsdfsd'不会错? 在线等...
解决方案 »
- oracle如何写“求连续N天库存为0的商品编码”的sql语句。
- 请问如何手动把query的数据赋值给dbgrid
- stringgrid的cell[1,1]得到焦點怎麼寫
- 请问如何设置DBGridEH的多行标头
- delphi ,sql 高手帮忙,急用,(我一边学,一边用,故不精)
- 既然COM和DCOM是语言无关的,那么其它语言的应用程序如何调用DELPHI写的COM或DCOM?
- Delphi6对中文支持的两个Bug...
- 如何把一个窗体中的同类控件赋相同的值???
- 请教如何调试一个SERVICE。NT4+DELPHI5+BOUNK CHECK6.5
- *****密码算法*****
- 请大家帮我把公式转成Delphi的代码~
- 请教我下面的读写注册表的语句,
还有就是有没有USES那个UNIT
Form2:TForm2;
begin
Form2:=TForm2.Create(Application);
Form2.Show;
end;由于变量的作用域问题,单元Unit2中的Form2和这里的Form2并不同,Unit2中的Form2实例不是没生成吗?
你说得很对, 准备接分.
另我想问下, 我是这样释放窗体的:
onclose里:action:=cafree;
ondestroy里:form2:=nil;不知对不对, 你是点做的?