Ask Experts Questions for FREE Help !
Ask
    CathyDAquarius's Avatar
    CathyDAquarius Posts: 1, Reputation: 1
    New Member
     
    #1

    Dec 18, 2007, 04:10 PM
    Recording a macro in Excel
    Need a macro that will select the cell one place to the left, edit the content, hit enter, and then move to cell below where started and repeat to end of column (last cell with a value).

    Example: 123-456789 is format of cell to be edited - need to remove the hyphen.

    Someone had created it for me - and I know they used Concatenate.. but I cannot do it - if I record, it is always going to same cell.

    Thank you.
    mdosh01's Avatar
    mdosh01 Posts: 64, Reputation: 8
    Junior Member
     
    #2

    Dec 19, 2007, 07:17 AM
    It sounds like you are using the "Record New Macro" function in Excel. Is that correct? Or will you be editing the macro directly in the editor?

    Also, the use of concatenate is a different issue from it always going to the same cell.

    What version of Excel are you using?

    Sorry can't more immediately.
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #3

    Dec 19, 2007, 07:45 AM
    Why do you need a macro? The formula:

    =SUBSTITUTE(A1,"-","")

    will remove the hyphen from the string. Place that formula in a cell in the same row and change A1 to the address of the cell you want to edit. Then copy the formula down to the end of the column. Finally, Select the column with the formulas and use Copy>Paste Special to paste as Values to the original column.

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

Excel vlookup and auto start macro [ 1 Answers ]

I've set up a vlookuop. I want to retrieve a blank value. Lookupup code is the number 1 and the value for one is blank. At one point it worked fine and now it won't. I've set up a main menu in excelfor excel worksheets in a workbook. When I bookmark a worksheet I would like a macro to autostart...

Excel: Macro to designate a color based on condition [ 1 Answers ]

I have an Excel which has three column. First has name(which might repeat in the coming cells) ,second has condition and the third has color. I want to count the number of color for a particular condition against each name Thanks Bhaskar KP

How to Automate a macro in excel [ 4 Answers ]

A program logs files at random in txt. abc_log.txt (example) When new info. Is added to the txt file,manualy activate macro and it does what it suppose to do, all OK there. Is there a way a macro code or excel, or perhaps a BAT program can be made to simply "detect" when new data is added...


View more questions Search