Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
emteam162
Creator
Creator

Changing order Column Table

Hi All,

Existe any way to change order column Straight table dynamic by macro ....

i have build my table dynamic and i want to show column straight table by order what i want.

Many thanks for your help.

Best Regards,

Emteam

3 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Use the MoveExpression and MoveDimension members of the StraightTableBox object.

Example from the apiguide qvw:

rem create new straight table and switch places of expression columns

set chart = ActiveDocument.Sheets("Main").CreateStraightTable

chart.AddDimension "ProductType"

chart.AddExpression "sum(Amount)"

chart.AddExpression "count(Product)"

chart.MoveExpression 1,0


talk is cheap, supply exceeds demand
emteam162
Creator
Creator
Author

Hi,

Thanks for your answer.

I'll try your solution .

Best Regards,

Emteam

emteam162
Creator
Creator
Author

Hi Gysbert Wassenaar

Could you please help me to do loop

I have ListBox (Name of my All Expression) my idea is when a select value from this listbox i bluid straigth table

ListBox Name of expression
D
E
G
M
Q

When i select by order in my listBox D,G,M i will have this table

DimensionDGM
AA123
BB 0
CC89420
DD12312515

Many thanks for your help

Emteam