Hello,
I'm trying to make a macro that will allow me to do some tests of data quality on a file that is read into it. Somewhat like the Field Summary tool, but I want to be able to specify the tests myself. For example, I want to count the number of blanks, and also the number of zeroes in an input data. If the data looks like this:
Input
I'd want the output to look like this
Output
I assume I'd have to build a macro for this, but I can't work out how to loop over an uncertain number of input fields Any help would be much appreciated
Solved! Go to Solution.
Hi @Hugo,
You can do this by using the field info tool to separate fields into each value type and transposing the data so you can process it.
I have put a very simple demo macro together to show what I mean.
Hopefully enough to get you started.
James
Hi @dunkerly79,
Thanks! The transpose followed by splitting out the different field types was the key.