I know this must be simple, but I'm apparently not finding the right Google search terms.
I have a function called foo, into which I want to pass some indeterminate number of arguments. Each argument will be the name of a page item.
For example: foo('P21_CUST_NAME','P21_CUST_CITY','P21_CUST_ZIP');
I want to iterate (loop) over the arguments and test the values of each item. Foo will return a string such as .y.n.y. which will then be searched to find any occurrences of .n. If any occurrences of .n. are found, then the page has not been completed fully, and I will show a red icon.
I want to build this as a general purpose function that can accept any number of arguments. The logic within the loop (i.e. null or not) is not at issue here. I can do that without a problem. I just need to know how to loop over every argument passed into foo, whether there is one argument, or three, or twenty-seven.
Thoughts, please?
Apex 4.2.3.00.08