Adjusting rows in sheet is messing up variables in rest of excel script

johnnyL

Well-known Member
Joined
Nov 7, 2011
Messages
4,546
Office Version
  1. 2007
Platform
  1. Windows
Unfortunately I am requesting a bit more help in learning Excel please.

I have Sheet2 set up as a table that I want to load values from.

I have 'declared', in the name box, names for each cell in sheet2. For example cell A5 is named 'CoinName1', cell A6 is named 'WebSite1', cell B5 is named 'CoinName2', cell B6 is named 'WebSite2'.

The problem I am encountering is when I manually 'cut/Insert cut cells' upwards/downwards to 'rearrange' the rows, the name box names also shift. I want the name box names to stay the same so that it doesn't mess up my other code.

For Example: If I 'cut/Insert cut cells' upwards from A6 to A5, I want cell A5 to still be named 'CoinName1' and cell A6 to still be named 'WebSite1', but as I have it now, cell A5 acquires the name of 'CoinName2' and cell A6 acquires the name of 'WebSite2'.

Is this easily fixable?
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
One of the advantages of using named ranges is that Excel keeps track of them when rows, columns, or cells are inserted or deleted. If your worksheet formulas, validation lists, ... employ the names, the formulas and lists are undisturbed by insertions and deletions. That's generally regarded as an advantage, not as a problem that needs to be fixed.

Maybe if you post your script and provide some more detail about what its intended to accomplish, someone can help you.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
Members
453,021
Latest member
Justyna P

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