Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a macro solution that seemed to randomly stop and my original assumption was that it was caused by bad coding or bad data of some sort.
But, after quite a bit of trouble shooting it looks like QlikView limits my for-statement to 100 even if my selection amounts to 100+ field values.
Short version of the macro:
Dim i
for i = 0 to mySelections.Count - 1
Dim FieldMainValue
FieldMainValue = mySelections.Item(i).text
ActiveDocument.Fields(FieldMain).Select FieldMainValue
Print_PDF FieldMainValue, "RP01"
Next
Is anyone aware of any settings/limits that could be changed?
Kind regards
Niklas
Hi Niklas, maybe you assign values to mySelections using a function like GetSelectedValues, GetPossibleValues... those functions has a parameter to limit how many values you want to get and 100 is the default value.
You can set another number:
ActiveDocument.fields("FieldName").GetPossibleValues(1000, true)
Hi Niklas, maybe you assign values to mySelections using a function like GetSelectedValues, GetPossibleValues... those functions has a parameter to limit how many values you want to get and 100 is the default value.
You can set another number:
ActiveDocument.fields("FieldName").GetPossibleValues(1000, true)
Amazing.
Was just about to check how many values that I had actually selected:
set mySelections = ActiveDocument.Fields(FieldMain).GetPossibleValues
Dim NrOfValues
NrOfValues = "Number of selected values: " & mySelections.Count
msgbox(NrOfValues)
And of course your were right.
set mySelections = ActiveDocument.Fields(FieldMain).GetPossibleValues(1000)
Thanks a lot!
Niklas