liandoje wrote:Hi forum
When I use Excel with TM1 addin, I can only undo for one level. However, when using standalone-Excel the undo function are more than 10 levels. Is there anyone experiencing this?
Regards
jeffry
Welcome to the Forum, but please take the time to read the various guidelines before posting. This, for example, does not meet the requirements for a bug post as outlined in the
sticky post at the top of that forum. It's been moved to the TM1 forum accordingly.
The problem that you've mentioned appears (in my experience) to apply when your action affects only a single cell. (This is based on XP/2003; I rarely use Excel 2007 with TM1. Indeed, I rarely use Excel 2007 unless someone has a gun to my head. However I won't be surprised if it applies to 2007/2010 as well.)
For example, if you type a character into cell A1 and then another one into cell B1, the only undo you'll have with TM1p.xla loaded is for the B1 entry.
However, if you select the range A1 to A3 and type something, then press [Ctrl]+[Enter] to fill all of the cells in that range, then do the same in B1 to B3, you'll be able to undo
both actions. The same sort of limitation also applies to pasting, whether that pasting is of values or formatting; if your target is a single cell, you will have only a single undo. If you paste a range, you'll have the normal number of undos. (Applying formatting directly to a cell seems to give the usual number of undos, but that doesn't change its value.)
I believe that this is an unfortunate side effect from the way that TM1 needs to take over the relevant change event of the worksheet to enable the writeback functionality of DBR/DBRW functions. In short, TM1 has to intercept the change to a single cell so that if the cell contains a DBRW formula, it goes up to the cube (following which the formula is restored) rather than simply going into the cell and obliterating the formula. In the process of doing this, however, the Undo chain is lost. This may not necessarily be a bug; it may be simply unavoidable because of the way the action is done. It would involve intermediate changes to the contents of the cell (from formula to value and back to formula again) which would
also normally appear in the undo stack. In short, TM1 may need to dump the undo stack to make sure that you don't corrupt your workbook by back-stepping into one of the steps that it was doing to send the value up to the cube.
Since you can use the native DBRW functionality to punch only a single figure in at a time, it isn't an issue when you change a range of cells at once and you therefore retain the standard Undo list in that case.