Macro to copy and paste on a loop with 2 conditions

MWOODY69

New Member
Joined
Mar 2, 2021
Messages
1
Office Version
  1. 365
  2. 2019
  3. 2016
Platform
  1. Windows
Hi Excel knowledge gods!

I can create basic macros but I am struggling with with this one!
What I am trying to do is create a macro to copy and paste two sets of characters, in A1 is the the first number (number of shelves), this can be any number from 1 to 20 (possible more), and the second number is is similar (locations). The shelves could be either 1 to 5 or A to E and the locations will always be a number 1 to 10
Example
In this example I am going to use A to E and the locations will always be a number 1 to 10
So what I need is for the user to pick whether it's a numeric or alphabetical (this part is easy), they then need to select the start (so using alphabetical as a option) they could select A to start and end with E (also easy).
The part I am struggling with is, in sheet 2 I need it to paste the value A1 in cell A1 then A2 in A2 ext until A10, then I need it to create B1 in cell A11 and continue until E10 is created

This is what I require for both alphabetic and numeric
AlphabeticalNumeric
A010101
A020102
A030103
A040104
A050105
A060106
A070107
A080108
A090109
A100110
B010201
B020202
B030203
B040204
B050205
B060206
B070207
B080208
B090209
B100210

Is this possible with a macro?
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,223,879
Messages
6,175,145
Members
452,615
Latest member
bogeys2birdies

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