Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello everyone,
please help me with setting up dimension limits with VBScript macro.
I can't find any reference in API how to do this.
If you have an example code please post it here.
If you have an idea where to look for documentation please respond as well.
Thanks in advance
Hi Victor,
API Guide contains some information, but it is not documented well, there are no examples and description.
You should check IOtherTotalSpecProp class.
see the following example
Top 10 Largest values:
set chart = ActiveDocument.Activesheet.CreateStraightTable
chart.AddDimension "ProductType"
chart.AddExpression "sum(Amount)"
set cp = chart.GetProperties
set dims = cp.Dimensions
dims(0).OtherTotalSpec.OtherMode = 1
dims(0).OtherTotalSpec.OtherCounted.v = 10
chart.SetProperties cp
Best Regards,
Ruslan
Hi Victor,
API Guide contains some information, but it is not documented well, there are no examples and description.
You should check IOtherTotalSpecProp class.
see the following example
Top 10 Largest values:
set chart = ActiveDocument.Activesheet.CreateStraightTable
chart.AddDimension "ProductType"
chart.AddExpression "sum(Amount)"
set cp = chart.GetProperties
set dims = cp.Dimensions
dims(0).OtherTotalSpec.OtherMode = 1
dims(0).OtherTotalSpec.OtherCounted.v = 10
chart.SetProperties cp
Best Regards,
Ruslan
It works! Thank you very much!
Any idea how to set properties in this way?
Greater than or Equal to 40% exact amount
Show Others
Hi,
what would you add to the script to tell it to reverse these dimension limits if they are set?
regards
Lukas