The cjGrid class is problematic in so much as if you use it you get sidetracked down alleys you don't need to go down.

I will explain what I mean.

I had a view that was non data aware but filled with data from various data tables.

At the bottom was a cCJGrid that got filled when application conditions changed.
However I realised that the grid made the overall view too high.

As this data in the grid was not needed to be viewed all the time I made a change
moving the grid to a new tabpage to the tabDialog that was above the grid

I added an extra page and move the cjGrid object there.

Compiled and run -ooops ok a COM error as the cCJGrid peAutoCreate is set to acNoCreate by default.

No problem just change the property to acAutCreate, compile an run, test, ok, Great easy.

Ok Exit the app to do further development -oh oh - cascades of COM errors on Exit Application

Unknown Method
set pbEnabled
send PrepareParams
send DefineParam
set pbPreserveEnvironment
RelaseObject x 6
Set pvComObject x 10



So what is a simple design issue becames now an issue on how to solve this - totally removed from the
design process.


PS

I solved the issue by setting the grid back to acNoCreate
and adding the code below to the View

- NOT elegant
and to my mind totally unnescassry if the cjGrid behaved as I would expect!

But I didnt have time to stuff around with the
problem as I need to get the view done and delivered


Procedure popup
Forward Send popup

Send Request_Switch_To_Tab of oTabDialog 4 0
Send Request_Switch_To_Tab of oTabDialog 0 0

End_Procedure


So the question remains why setting the cjGrid to be AutoCreate causes such a problem ??

I have many other COM controls that I set this property to acAutoCreate and they behave as expected.