请教一下:用什么api函数可以获得一个MDI窗口的子窗口的handle,
请举个例子,最好把参数说明一下,谢谢
请举个例子,最好把参数说明一下,谢谢
解决方案 »
- 集思广益,怎样用最少的代码最高效的与数据库进行交互!
- TreeView在设计时的展开问题
- 急问一个三层开发的问题------在线等待,急急急!
- 怎样将TOleStream的值写到TMemoryStream内
- 一个关于TComboBox控件的没有OnMouseDown事件的问题,怎么办??? 急。。。在线等待
- 材料出入库,如何建表最理想?(网络版)
- 问大家一个关开TChart.LineSeries 的问题
- GLscene中的高级建模工具extrusionsolid怎么使用呢?
- $后面加数字是什么意思?
- 怎样对动态生成的控件进行事件的截获。
- 简单问题,如何判断焦点
- 请大家帮忙看看这个语句有什么问题?
var
iLoop: integer;
iCount: integer;
aHandle: THandle;
aFormClass: TFormClass;
aTempForm: TForm;
begin
iCount := 0;
for iLoop := 0 to main_f.MDIChildCount-1 do
begin
if UpperCase(main_f.MDIChildren[iLoop].ClassName)=UpperCase(ModuleFormName) then
begin
inc(iCount);
aHandle := main_f.MDIChildren[iLoop].Handle;
SendMessage(aHandle,WM_SYSCOMMAND,SC_MAXIMIZE,0);//找到了
Break;
end;
end;
if iCount=0 then
begin
aFormClass := TFormClass(GetClass(ModuleFormName)); );//沒有找到
if aFormClass<>nil then
begin
aTempForm := aFormClass.Create(Application);
aTempForm.WindowState := wsMaximized;
end;
end;
end;
//
OpenModule('TFormName');//打開MDI窗口