L
Legacy 139986
Guest
I have a macro that updates a series of pivot tables based on a field selection in the pivot table, for example, in the page filter I select the 'sales region' (North, South, East, or West) and in the 'product' (apples, oranges, pears or bananas). It works great as long as there is data to display. If there is no data for bananas in the North region the macro errors out and displays the end or debug message. There almost always is no data for bananas in the North (keyword 'almost'). What can I add to my macro that will say 'If there is no data, display a message that says 'No data for the selected item' and defaults to 'All' products? Needless to say my problem is a little more complicated than this in that there are several macros for several combinations but the problem is the same for each of them if there is no data to display. I hope someone can help.