Ron_de_Weijze
asked on
'Cannot focus a disabled or invisible window' on Win98, not XP.
Hi,
I use Delphi 7 Studio Enterprise on two machines (no network, just for comparison). The application I have runs on the XP machine flawlessly, but on the Windows 98 machine I keep getting "Project raised exception class EInvalidOperation with message 'Cannot focus a disabled or invisible window'. Process stopped. Use Step or Run to continue.
When I close the errormessage, the code that raised the exception turns out to be:
procedure TPropertyFrm.ShowContents( XObject : TObject);
begin
IL_Property.Assign(MyProgr amMain.IL_ Nav);
m_Closing := FALSE;
if ED_Caption.Visible and ED_Caption.Enabled then
try
ActiveControl := ED_Caption; // <------- here is the hangup
except
end;
DoDataExchange(FALSE);
end;
I compared the installation settings on both standalone machines and made the as similar as possible. Yet the problem stays.
What do you make of this?
Thanks,
Ron dW
I use Delphi 7 Studio Enterprise on two machines (no network, just for comparison). The application I have runs on the XP machine flawlessly, but on the Windows 98 machine I keep getting "Project raised exception class EInvalidOperation with message 'Cannot focus a disabled or invisible window'. Process stopped. Use Step or Run to continue.
When I close the errormessage, the code that raised the exception turns out to be:
procedure TPropertyFrm.ShowContents(
begin
IL_Property.Assign(MyProgr
m_Closing := FALSE;
if ED_Caption.Visible and ED_Caption.Enabled then
try
ActiveControl := ED_Caption; // <------- here is the hangup
except
end;
DoDataExchange(FALSE);
end;
I compared the installation settings on both standalone machines and made the as similar as possible. Yet the problem stays.
What do you make of this?
Thanks,
Ron dW
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
But the problem, so hidden, remains :)
ASKER
That's right, but this will do for now. Thanks again.
ASKER
Thank you!
Ron dW