Subject Re: [IBO] Multiple TIB_CtrlGrid causes Design Error
Author kumasoftllc
I have uploaded the file TIBCtrlGridBug.zip.

1. Open the project.
2. The MainForm is shown by default.
3. Use Shift+F12 to open Form2. This form uses multiple
TIB_CtrlGrids with the DataSource property set.
4. Add either a TIB_Memo or a TIB_ComboBox (with Style of
csDropDownList).
5. Use "Close All" to close the project and save your work.
6. Reopen the project.
7. Use Shift+F12 to open Form2 and recieve the error "Error creating
form: Cannot focus a disabled or invisible window".
8. Use "Close All" to close the project.
9. Reopen the project.
10. Use Shift+F12 to open the data module first.
11. Use Shift+F12 to open Form2 without error.

The problem appears to be opening a form with the specified elements
(TIB_CtrlGrid with DataSource set and TIB_Memo/TIB_ComboBox (with
Style of csDropDownList) when the currently focused form has a
TIB_Dialog (note the TIB_StatusDialog on the MainForm).

Focusing on a Form without a TIB_Dialog prior to using Shift+F12 will
allow Form2 to open without error.

Removing the TIB_Dialog from the MainForm will allow will allow Form2
to open without error.

Thanks

Bob

--- In IBObjects@yahoogroups.com, "IB Objects" <jwharton@i...> wrote:
> I'll log this as a bug and if possible being able to have a sample
app on
> file would be appreciated.
>
> Kind regards,
> Jason Wharton
> http://www.ibobjects.com
>
> ----- Original Message -----
> From: "kumasoftllc" <kumasoftdev@b...>
> To: <IBObjects@yahoogroups.com>
> Sent: Thursday, June 05, 2003 5:34 AM
> Subject: Re: [IBO] Multiple TIB_CtrlGrid causes Design Error
>
>
> > I have finally tracked down the source of the problem, and believe
> > that it might be a bug.
> >
> > When I have a form with multiple TIB_CtrlGrids, each with the the
> > DataSource property set, I can consistently reproduce the problem
by
> > doing 1 of 2 things:
> >
> > 1. Place a TIB_Memo in any of the grids.
> >
> > or
> >
> > 2. Placing a TIB_ComboBox in any of the grid and setting the Style
> > to "csDrowDownList"
> >
> > I have verified the root cause of the problem on both the original
> > form and a new form that I created from scratch (without using
cut-
> > and-paste and paying careful attention to the creation order).
> >
> > Any ideas?
> >
> > Thanks.
> >
> > Bob
> >