View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Isis[_2_] Isis[_2_] is offline
external usenet poster
 
Posts: 51
Default Still need help with a code reference problem - Excel 2002 XP

I have a problem (in fact several) with a workbook. Under certain
conditions (absolutely reproducable) the sheet seems to reference a code
block that does not exist - I have a pic of the window that appears here;

http://www.jimsthings.com/excel/Fill_Rota.png

the workbook that produces the error is here;

http://www.jimsthings.com/excel/8_test.xls

the sheet affected is the open sheet (Timesheet) - if I click on any of
the cells A:44 to A:60 (approx) I get the error window shown in the
picture above.

Several people have helped by saying that this seems to be at least
partially due to the fact that one of my buttons at the top right - 'Get
Staff' - 'Rota' and 'Clear All' are operating on 'protected' sheet and so
I need to unprotect it before running the code.

Unfortunately, none of the people whi have helped are running the same
version of excel as me and the other sheet users - we use Excel 2002 SP3
from Office XP, and maybe the things that are working for them are not
working correctly here, although, I stress, I am very grateful for the
help and do not want to appear ungracious !

There are in fact then 2 problems, one is the functionality that I am
unable to build in, the other is that I would like to understand why this
nonexistent code block still seems to be referenced.

Short background info - the sheet is used by a parent who manages a 'care
package' for their son - staff who look after him are rota'd and their
pay worked out by the sheet. As they are definately not pc savvy I need
to lock down as much of the code and formulae as possible to prevent
accidents happening while the sheet is being used - thats why I have
protection turned on and only some cells protected.

The 'Rota' Button fills the grid on the 'Timesheet' sheet with a months
worth of names Rota'd on the 'Rota' sheet (Rota sheet just has a weekly
schedule).

The 'Get Staff' button assembles a list of all the names appearing in the
Rota grid of sheifts on the 'Timesheet' and copies them to cells below
the working area in column 'A'.

The 'Clear All' button clears all the names, shift hours and pay rates
out as well as clearing the list of unique names produced by the 'Get
Staff' button.

As it stands the sheet is in 'problem' condition - the only way I can
clear that is to unprotect the sheet and then 'Clear All'.

The problem created by using the 'Get Staff' code - it has been narrowed
down to the code that does the filtering to produce the unique list in
column 'A' - this list is created by copying all the names data from
columns B, C, E, F, H and J to column AP and then filtering it - after
which the temp data in column AP is deleted.

Any suggestion or help would be most welcome.

Thanks