Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
On Demand Webinar: See Why Thousands of QlikView Users Have Switched to Qlik Sense. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to get a chart visible from a container

Hi guys,

I'm trying to get visible or not a chart when I choose to see a chart in a container ?

Let me explain.

I have a container with two charts.

If I see the first chart nothing has to happen. If I choose the second chart in the container I'd like to get visible a chart (this chart is not in the container).

Is there possible?

Thanks in advance

Best regards

Giampiero

8 Replies
lironbaram
Partner
Partner

hi as far as i know selecting chart in the container is not an event that you can use as trigger

but you can put the two graphs you want to see together in a grid type container

then include this container in your main cinontaer attach is an example

eran_dayan
Contributor III
Contributor III

Hey,

you can do that by using a macro.

The macro returns to a veraible the sirel number of curent object.

1. Replace the container number (CT01)

2. Create a  Variable named Container

3. Set the macro as an object triger In sheet prooerties under triggers, Sheet object event trigers, on active

sub Container

    Set ContainerObj= ActiveDocument.GetSheetObject("CT01") '

    set ContProp=ContainerObj.GetProperties       

    activeIndex= ContProp.SingleObjectActiveIndex

    set b = ActiveDocument.Variables("Container")

    b.SetContent activeIndex ,true

 

end sub

Works for me

Not applicable

Hi Eran,

Thank you for reply.

I've just seen your qvw. May be I didn't understand but it seems it doesn't work.

I mean, if I choose one of the chart in the container I will expect to see appear a new chart but nothing happen.

Have I made something wrong?

Regards

Giampiero

Not applicable

Hi liron,

I see.

Nice workaround. I have to understand if I can use it in my case.

Thank you so much.

Best regards

Giampiero

eran_dayan
Contributor III
Contributor III

Look at the varieble in the text box, it changes when you choose one of the charts.

Try now

Not applicable

I'm sorry, the variable doesn't change value.

I have 11.20 qlikview version

Regards

Giampiero

eran_dayan
Contributor III
Contributor III

Your right!

It dosent work in version 11, i'm using ver 10 and it works find.

I canot find a way to set an object triger in ver 11..

Not applicable

I see.

Thank you for your help.

Regards

Giampiero