Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Find out the number of count in a feild for a specific value

So far I am using the following:

ActiveDocument.Evaluate("=GetSelectedCount(Currency)") -> to find out the number of count for 'Currency' field

ActiveDocument.Fields("Currency").Select "USD" -> to select the 'Currency' field with value 'USD'

However, I 'don't want to make any selection', I just want to find out the number of count of 'USD' in 'Currency' field, what is the VBA syntax would be?

1 Solution

Accepted Solutions
tresesco
MVP
MVP

May be like:

ActiveDocument.Evaluate("=Count({<Currency={USD}>}Currency)")

View solution in original post

3 Replies
tresesco
MVP
MVP

May be like:

ActiveDocument.Evaluate("=Count({<Currency={USD}>}Currency)")

Not applicable
Author

one correction should be Currency={'USD'}

tresesco
MVP
MVP

If your string is not separated by space ,quotes are optional. Therefore USD would work without quotes as well.