Create new macro

fozo

New Member
Joined
Mar 13, 2013
Messages
24
Hello everyone,

I am trying to attempt to get my first macro on excel.

Here is what it looks like. I have 3 column A-C.

On cell C1: I want to have the word "Hold", then highlight the cell with red color back ground. Then, it goes to column A and clear up the content on cell A1.

How can I write macro for it?

Second question: how do I use that macro to apply whichever cells below?

Hope I don't confuse you guys.

Thanks.
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
When you used the macro recorder to record the steps you described, what did it come up with?
 
Upvote 0
Hi jolivanes! Great quote by the way.

Well I am new here and I am looking for an answer to my thread but I think I can help you!!! :)

After doing your macro recorder, open VBA, and all the code is there. You then can pick up what do you want for another macro recorder and as well change what it is written.
 
Upvote 0
Hi fozo, There is nothing magical about writing macros. It is simply using the VBA program language to identify workbook, worksheet and control objects and their properties and execute events in a logical order. Most simple macros can be written using the macro recorder. Just turn the recorder on, then proceed to do the steps manually that you want the macro to do, then turn the recorder off. Test the macro to see if you get the results you want. If not, then post the macro you recorded to a thread on this site, with an explanation of what you were trying to do, and somebody will likely assist you in getting the macro to work. Most recorded macros do not look like what you see from responders on this site. The recorded macros are much more wordy with a lot of select and scroll. That is because the recorder will record your every action, even the ones that are meaningless. After you learn something about macros, you will be able to record one and then clean it up so it does not look so bulky.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,203,388
Messages
6,055,126
Members
444,763
Latest member
Jaapaap

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