Check database for existing data

stirlingmw1

Board Regular
Joined
Jun 17, 2016
Messages
50
Office Version
  1. 2016
  2. 2013
  3. 2010
  4. 2007
Platform
  1. Windows
Morning All, I hope everyone is well.

I am trying to put together a workbook for my wife to monitor her care home residents care needs. I have managed to complete 90% of the workbook so that a monthly inspection report can be generated. Basically a month and years is selected within Sheet1 ("Main"). If a report exists meeting that criteria that worksheet is selected, however, if a report meeting that criteria does not exist that a worksheet is made by copying "Template" worksheet and renaming is using the month and Year entered on the Main worksheet e.g. Jan_2021.

I have also manged to take specific data from this new worksheet (A9:B31 (Room No, Name), O9:R31) and add it to "Stats" worksheet (Columns B (Room No), C (Name), D (Month), E (Year), F (data from column O), G (data from column P), H (data from column Q), I (data from column R). This I have managed to do as long as it is the first time the data is added. Added to next available row. This worksheet will be used to monitor trends for each resident.

Problem:
I can open any of the generated worksheets and amend data within. Changing data within these worksheets will affect data that is in O9:R31. What I am struggling with is if any existing worksheets are changed the data that is stored in "Stats" sheet needs to be updated too. The Room Number, Name, Month and Year will not change and could be used as a check criteria to see if the data exists.

I hope I have explained this properly.

TIA

Steve
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,152,194
Messages
5,768,775
Members
425,492
Latest member
blueexcel123

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top