I am currently encountering problems attempting to add a new worksheet after the current end worksheet in Excel.
The parameters are:
[lDISPATCH Add:=]Add [VARIANT Before][,VARIANT After][,VARIANT Count][,VARIANT Type]
And then the help file kindly gives me the following example...
ActiveWorkbook.Sheets.Add Before := Worksheets (Worksheets.Count)
This is all very well... but it doesn't help when you need to write the code from within Navision.
I can quite happily keep 'adding' worksheets by inserting them before the active one (default functionality)
Does anybody out there have the answer?
Thanks in advance
<img border="0" title="" alt="" src="images/smiles/icon_confused.gif" />