form1是主窗体
form2中有1个单选钮对象"radiogroup1"我在form1的一个自定义函数中写下
"if form2.radiogroup1.checked=True then showmessage('ok');"可以编译通过.
但运行到此处时提示出错.不知错在那里?
form2中有1个单选钮对象"radiogroup1"我在form1的一个自定义函数中写下
"if form2.radiogroup1.checked=True then showmessage('ok');"可以编译通过.
但运行到此处时提示出错.不知错在那里?
解决方案 »
- FormCreate 中的语句不被执行
- 求带附件soap协议传输代码 Delphi
- 为什么我的Listview只能选中第一列???急等答案~~~~
- 寻找答案。。。
- 怎样读取十六进制文件?????
- 一台电脑,连接三个等离子显示屏,一个普通电脑显示器,如何实现录入及显示?
- 来看一下吧,Delphi7中怎么一行一行读取Unicode文件(求助)
- 调用DLL中函数产生Invalid pointer Opreation 问题(不是返回string)
- 有谁有DELPHI 7,UPDATE 1
- 我中午准备吃数据模块。。。。。
- 那位用到RBuilder的ppDesigner,怎样将其汉化呀?(进来看了不后悔)
- 拜师帖!jpyc (九品御厨)进来 !!! 大家都来顶
菜单 file->use unit...
然后选择 unit2(unit2 是form2的文件,unit1 为form1)方法二:
在代码编辑框
implementation 后面加上
uses Unit2;
try
ShowModal;
finally;
free;
end;
end;并且已在form1的implementation 后面加上uses Unit2;
with TForm2.Create(self) do
try
ShowModal;
if radiogroup1.checked=True then showmessage('ok');
finally;
free;
end;
end;
at first, you must use 'unit2.pas' in unit1.pas ,then you can add the code:
procedure.......
begin
form2.button1....
end;
that is so easy!