<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:st1="urn:schemas-microsoft-com:office:smarttags" xmlns="http://www.w3.org/TR/REC-html40"
xmlns:ns0="http://msdn.microsoft.com/mshelp" xmlns:ns1="">

<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><o:SmartTagType
 namespaceuri="urn:schemas-microsoft-com:office:smarttags" name="place"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
p.TableHeading, li.TableHeading, div.TableHeading
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";
        font-weight:bold;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:595.3pt 841.9pt;
        margin:72.0pt 90.0pt 72.0pt 90.0pt;}
div.Section1
        {page:Section1;}
-->
</style>

</head>

<body lang=EN-GB link=blue vlink=purple>

<div class=Section1>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Edward,<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp; What an elegant solution!<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>&nbsp; Of course it will miss out any child
controls that don&#8217;t have a window handle, but there&#8217;s not really
anything that you can do with them from an external program anyway.<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Trevor<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<div>

<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span lang=EN-US style='font-size:12.0pt'>

<hr size=2 width="100%" align=center tabindex=-1>

</span></font></div>

<p class=MsoNormal><b><font size=2 face=Tahoma><span lang=EN-US
style='font-size:10.0pt;font-family:Tahoma;font-weight:bold'>From:</span></font></b><font
size=2 face=Tahoma><span lang=EN-US style='font-size:10.0pt;font-family:Tahoma'>
delphi-bounces@delphi.org.nz [mailto:delphi-bounces@delphi.org.nz] <b><span
style='font-weight:bold'>On Behalf Of </span></b>Edward Huang<br>
<b><span style='font-weight:bold'>Sent:</span></b> Wednesday, 1 October 2008
7:30 p.m.<br>
<b><span style='font-weight:bold'>To:</span></b> NZ Borland Developers Group - <st1:place
w:st="on">Delphi</st1:place> List<br>
<b><span style='font-weight:bold'>Subject:</span></b> Re: [DUG] Number of
controls on a parent control</span></font><span lang=EN-US><o:p></o:p></span></p>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<div>

<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Hi Jeremy,</span></font><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>&nbsp;<o:p></o:p></span></font></p>

</div>

<div>

<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>If you got the window's handle, you can
use the Windows API&nbsp;</span></font><u><font color=blue><span
style='color:blue'>EnumChildWindows</span></font></u><font color=black><span
style='color:black'> </span></font><font size=2 color=blue face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:blue'>to enumerate all
child&nbsp;windows.</span></font><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>&nbsp;<o:p></o:p></span></font></p>

</div>

<div>

<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Look at Windows API help file, you should
be able to figure out how to use the API.</span></font><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>&nbsp;<o:p></o:p></span></font></p>

</div>

<div>

<p class=MsoNormal><font size=2 color=blue face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:blue'>Edward</span></font><font face=Tahoma><span
style='font-family:Tahoma'><o:p></o:p></span></font></p>

</div>

<div>

<p class=MsoNormal><font size=3 face=Tahoma><span style='font-size:12.0pt;
font-family:Tahoma'><o:p>&nbsp;</o:p></span></font></p>

</div>

<div>

<p class=MsoNormal style='margin-bottom:12.0pt'><font size=2 face=Tahoma><span
style='font-size:10.0pt;font-family:Tahoma'>&nbsp;-----Original Message-----<br>
<b><span style='font-weight:bold'>From:</span></b> delphi-bounces@delphi.org.nz
[mailto:delphi-bounces@delphi.org.nz]<b><span style='font-weight:bold'>On
Behalf Of </span></b>Jeremy Coulter<br>
<b><span style='font-weight:bold'>Sent:</span></b> Tuesday, 30 September 2008
11:22<br>
<b><span style='font-weight:bold'>To:</span></b> NZ Borland Developers Group - <st1:place
w:st="on">Delphi</st1:place> List<br>
<b><span style='font-weight:bold'>Subject:</span></b> [DUG] Number of controls
on a parent control<o:p></o:p></span></font></p>

</div>

<blockquote style='margin-top:5.0pt;margin-right:0cm;margin-bottom:5.0pt'>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Hi All.....before you all say
&quot;mycontrol.controlcount&quot;&nbsp;&nbsp; I cant do that :-)<br>
<br>
What I am doing is trying to get some text from a control on a control that is
on another application.<br>
So I need to send a windows message to get the control count.<br>
The reason for this is, the name of the control I am trying to get hte name of
is different every time.<br>
<br>
Basically I need to do this :-<br>
<br>
//find the parent window - done<br>
//find the parent control - done<br>
//loop the controls on the parent control's child controls<br>
//get the text from the control I want to look at.<br>
<br>
I hope what I am trying to do is res. clear&nbsp;&nbsp; :-)<br>
<br>
Jeremy<o:p></o:p></span></font></p>

</div>

</blockquote>

</div>

</body>

</html>