Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a straight table in one of the sheet. The straight table consist of 2 dimensions and 2 expressions. Each expressions has pretty long formula.
I created a summary sheet; intending to show the number of record found in the table mention earlier.
Originally, I use function "count" and try to combine the formula of the 2 expressions. It works but not all time. If I load the qlikview with different data set, the count does not always return the same number of lines in the straight table.
I wonder if there is any function that I can use to get the number of lines of a certain object in a qlikview?
Thanks.
Pound.
Thank you John and Michael.
I marked both your replies as "answer"
For those searching the same thing.
1. Create a variable. From menu -> Settings -> Document settings -> Variable tab. Just add and give it any name. For my macro, the variable name is "myVar"
2. Select the macro type and click on Edit Module
3. Enter macro like this
poundesville wrote:
Sub NoOfRows
set chart = ActiveDocument.GetSheetObject("CH77")
ActiveDocument.Variables("myVar").SetContent chart.GetNoOfRows, true
end Sub
Tried this macro and it doesnt work for me. I get a message the the object does not support the property. I looked in the api guide and i dont see and GetNoOfRows associated with charts. Hmm.
Tim,
Waht type of chart is it? GetNoOfRows exists for straight table only.
(Unless it is different depending on QV version as well)
Hi:
rowno() gives you the number of the row you are.
If you have more than 1 dimension, it initializes every change of dimension. Use then rowno(Total) and youll have the rowno without considering dimensions.
It works the same for columnno(), columnno(Total). Very useful to inter record calculations like accumulating any column or row together with rangesum and range any function.