6
2
Excel 2010 Professional Plus (32bit) seems to have created a new set of worksheets and renamed all the original worksheets in the VBA screen, e.g. Sheet10 becomes Sheet101, Sheet13 becomes Sheet131. This causes the UDF to stop functioning. The "new" "sheet10" and "sheet13" do not seem to exist anywhere but in the VBA project window. The "new" sheets have a blue icon next to them.
The UDF does work. Until these new sheets are created and the old sheets are renamed. There are only 12 worksheets & one workbook in the Excel file. The VBAproject shows 2 workbooks & 20 worksheets.
1) What causes this?
2) How can I fix it?
3) How can it be prevented?
Added images showing the properties of non-existent of "sheet3" and properties of real sheet "sheet31". All of the non-existent sheets & workbook have a long list of properties.
XLS file here You'll have to download it since it opens in google's viewer.
UPDATE: 1/6/2016 So as of today, the formulas in this XLS are all errors (#VALUE) when I opened it. Excel has not created the non-existent sheets as seen in my last update. Last week the XLS & formulas were working and I made no changes. This is the new workbook I copied all the sheets to as suggested in the posts below. The original workbook (the one shown in the pix w/ the non-existent worksheets) does not have the #VALUE errors. Both workbooks are on the same computer and have been updated together over the last month+ for comparison purposes.
UPDATE3, 1/6/2016 I just accidentally moved a text cell, then clicked undo, and all the #VALUE errors went away and I now have all the right calculations. WTF.
You can try copying sheets to another workbook, as stated here
– ZygD – 2015-11-30T00:51:21.797So if you target them by their index numbers, are they correct? – Raystafarian – 2015-11-30T15:12:53.190
@ZygD - I have copied the sheets. It did this again. I can't copy the sheets to a new workbook every time it screws up. – mechengr02 – 2015-12-02T18:21:29.413
@Raystafarian - what do you mean "target them by their index numbers"? If you mean reference the sheet numbers, referencing a sheet # goes to the sheet with that number. If it references a sheet that does not exist, it fails. – mechengr02 – 2015-12-02T18:22:19.040
check here - you'll probably need to copy the sheets. Nobody seems to know a cause, so unless Joel shows up... Also here's another (10th reply) – Raystafarian – 2015-12-03T12:27:29.973
Are you going to the internet (via ie) anywhere in the code? – Raystafarian – 2015-12-03T12:34:34.783
I'm not going to the internet in the VBA or xlsm. I'm not creating new sheets via VBA. I have copied the sheets to a new workbook and it happened again. – mechengr02 – 2015-12-03T16:21:08.793
Can you delete the blue sheets with VBA? If so you could loop through the
Worksheets
collection and delete any where theName
doesn't match any of the sheets that are supposed to be there. Just be careful if you need to add sheets. Or can you close the blue workbook with VBA? – Kyle – 2015-12-05T01:40:50.1472Is there any way you can provide a link to the file so we can take a look at the project explorer objects? – Raystafarian – 2015-12-06T10:26:17.240
I can't seem to find any documentation. I took a look through
C:\Program Files\Common Files\Microsoft Shared\VBA\VBA7.1\VBEUIRES.DLL
which seems to contain most of the icons for the VBE but I couldn't spot it. – Raystafarian – 2015-12-06T11:40:38.187Link to file provided in main question. – mechengr02 – 2015-12-07T17:15:54.833
All I'm getting is runtime error 429
activex componednt can't create object
andlicense information for this component not found. You do not have an appropriate license to use this functionality in the design environment
How was this developed? You also have 2thisworkbook
modules – Raystafarian – 2015-12-09T16:15:41.087"thisworkbook" is in there 2x because that is part of the original stated problem. Excel created it. – mechengr02 – 2015-12-09T21:59:03.543
I don't think I've ever seen "runtime error 429" in this workbook. This xls and VBA were developed in Windows 7 and Office 2010, start to finish. – mechengr02 – 2015-12-09T22:03:37.030