Continuous Macro

hstsunflower

New Member
Joined
Sep 11, 2020
Messages
8
Office Version
  1. 365
Platform
  1. Windows
Hi There,

Is it possible to create a Macro that will continue through the end of my worksheet and be useable on other worksheets even if the number of rows with data changes?

ie; my worksheet contains 13526 rows. I would like to create a macro that will do the following in the same column down thru row 13526:
Selection.End(xlDown).Select
Range("A122").Select
ActiveCell.FormulaR1C1 = "x"
Selection.End(xlDown).Select
Range("A124").Select
ActiveCell.FormulaR1C1 = "x"
Range("A125").Select

and continue down through all rows to the end of row 13526.

I would also like to use this macro in other worksheets however the number of rows will definitely vary.

Thanks in advance for your help.
 

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
In that case you should get what you showed in post#9
 
Upvote 0
Yes. They are empty except for the bold titles shown in snip above. (ie; "Keep", ""A" FRAME", etc).

I just need a code that enters an ex in every immediate row below the title. All other rows will remain blank.

ie:
end
down arrow
down arrow
x

I need that repeated through the entire worksheet for column A.
 
Upvote 0
That is what the code will do, if the cells are truly empty.
 
Upvote 0
Question: Where can I get decent Macro, Pivot Table and VB code online lessons without paying an arm and a leg for. I have beginner experience but looking to build on that.

Thank you.
 
Upvote 0
I have no idea I'm afraid.
 
Upvote 0

Forum statistics

Threads
1,215,001
Messages
6,122,648
Members
449,092
Latest member
peppernaut

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