Help with Named Ranges in VBA

ManUBlueJay

Active Member
Joined
Aug 30, 2012
Messages
326
Office Version
  1. 365
Platform
  1. Windows
I have been using Named Ranges in VBA for years, but recently it gives me a runtime error when there is a formula in a named range.
If I put the formula Sum (b1:c1) in A1 and refer MyRange to A1 it works fine in VBA. However when I put the formula Sum (b1:c1) directly in to MyRange I get a run time error in VBA yet I can call MyRange in Excel and it will function correctly.
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
After digging deeper it says it is missing MSCOMCT2.ocx. This file used to have the MSDatepicker which is no longer available for 64 bit office.
I rengerated the file in Windows 7 and everyting works perfectly. I removed the Datepicker and the code alluding to it. WHat else must I remove so the file can be opened in Windows 10 64 bit operating system without it looking for this file
 
Upvote 0
Open the file in Windows 10, remove the reference to MSCOMCT2.ocx under Tools>References..., save the file and then you should be fine.
 
Upvote 0

Forum statistics

Threads
1,224,828
Messages
6,181,204
Members
453,022
Latest member
RobertV1609

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
Back
Top