Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Pascal Delphi Components Writing > Re: TSrinGrid h...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 10 Topic 77 of 155
Post > Topic >>

Re: TSrinGrid has no parent

by paulmccabe51@[EMAIL PROTECTED] (PMC) Jul 28, 2004 at 06:44 AM

Thanks a lot Robert, you confirmed my own feelings that the answer is
not a simple one

I have stepped into the Ancestor cl***** whilst debugging

procedure TWinControl.SetFocus;
var
  Parent: TCustomForm;
begin
  Parent := GetParentForm(Self);
  if Parent <> nil then
    Parent.FocusControl(Self)
  else if ParentWindow <> 0 then
    Windows.SetFocus(Handle)
  else
    begin
      Self.HandleNeeded;
      ValidParentForm(Self);
    end
end;

For a checkbox and StringGrid, Parent is both nil.
However the StringGrid ParentWindow = 0 whilst the checkbox
ParentWindow has a value

The checkbox works fine but the StringGrid throws the 'No Parent
Window Error' at :

 ValidParentForm(Self)

As I say I am new to this but will continue to chip away at it, any
help or advice appreciated
 




 10 Posts in Topic:
TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-07-26 00:56:10 
Re: TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-07-26 08:27:32 
Re: TSrinGrid has no parent
"Bruce Roberts"  2004-07-26 11:49:00 
Re: TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-07-28 06:44:15 
Re: TSrinGrid has no parent
"Bruce Roberts"  2004-07-28 15:01:27 
Re: TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-07-29 01:39:09 
Re: TSrinGrid has no parent
"Bruce Roberts"  2004-07-29 09:29:36 
Re: TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-07-29 07:54:03 
Re: TSrinGrid has no parent
Jamie <jamie_5_not_val  2004-08-01 10:43:36 
Re: TSrinGrid has no parent
paulmccabe51@[EMAIL PROTE  2004-08-02 02:25:37 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 5:00:33 CST 2008.