I was in need of a solution to enhancement a Macro to compare values in variables before proceeding in my Macro. The solution works nicel and can be found here: http://community.qlik.com/thread/58147
However, I'm having a strange issue with this...
When I make selections which results in 605 rows of data. This value gets stored in the variable vRowCount. My maximum allowed, 500, is stored in vMaxRowCount. When I use the below Macro it behaves as expected:
'First we determine which object and how many rows of data it has.
Set obj = ActiveDocument.GetSheetObject( "CH001" )
Set CellMatrix = obj.GetCells( CellRect )
'Then we update the variable vRowCount to be the number of rows of the object.
'When the export finishes we display the below message:
However, when I make selections which result in 4,592 rows of data it stores the value in vRowCount but still exports the data to Excel. It should display the MSGBOX and stop. Any ideas as to why it would do this?