Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

Not applicable

Issue with container object

Hello friends,

i am working on the container object. i have 2 container objects each having 6 objects in it. The first container contains all Gauge charts and 2nd container contains 6 bar charts. if i select any one of the gauge chart in first container, the corresponding bar chart in the 2nd container should be activated.

For ex: if i select 3rd object in the 1st container, the corresponding bar chart in the 2nd container should be activated and vice versa.

The objects in the first container is showing aggregate information(using gauge chart) and objects in the 2nd container is showing trend (using bar chart).

Please help.

Regards

Siva

4 Replies
Not applicable

Re: Issue with container object

Hello friends,

I forgot to mension the version of Qlikview in the previous post, its Qlikview 10.

Regars

Siva

iliyansomlev
Contributor

Re: Issue with container object

Please see the attached qvw. I have found the macro code in http://community.qlik.com/message/279672#279672

You need to copy paste it as many tabs as you have - I did it here for 3 tabs/objects in 2 containers. The logic is the same.

It is not exactly what you want - to activate second container's corresponding tab when clicking on another in the first container (I think there is no way to do it like this or maybe there is, but the macro code would be more complicated) ;

instead it has 3 (in you case they will be six - you can make them quite small and nice looking) buttons to trigger corresponding Tabs in both containers.

Btw, I think it would be much better for the layout to do it in this way, and not have name on tabs of each container that will make the eyes tired. Just name the containers Aggregate / Trend and then name the six buttons - you'll have only 8 names (versus 14 in the case you name the Tabs as well.)

Not applicable

Re: Issue with container object

Thanks a lot for your prompt reply.

Iam getting the following error. The qlikview version is 10.

Object doesn't support this property or method: 'ContProp.SingleObjectActiveIndex'

The code is:

sub ContTabSelect0


Set ContainerObj = ActiveDocument.GetSheetObject("CH21")
set ContProp=ContainerObj.GetProperties
ContProp.SingleObjectActiveIndex = 0

ContainerObj.SetProperties ContProp

Set ContainerObj = ActiveDocument.GetSheetObject("CH20")
set ContProp=ContainerObj.GetProperties
ContProp.SingleObjectActiveIndex = 0

ContainerObj.SetProperties ContProp


End Sub

where CH20 & CH21 are the charts object id's

Regards

Siva

iliyansomlev
Contributor

Re: Issue with container object

Well, maybe this API is not supported in QV 10. I have QV 11 and it works for me.

In http://community.qlik.com/message/275538#275538 there is another macro code, somewhat different but uses the same function. Maybe it won't work with QV 10 either, but have a try at least (check the attched qvw). Hope it will help.

Community Browser