Paste Special - Keep formatted cells

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • MAdcock
    New Member
    • Nov 2006
    • 13

    Paste Special - Keep formatted cells

    I have created a VB code to export data from one worksheet to another, with rows deleted depending upon the value of a cell. My problem is that when this is copied and pasted to the new worksheet, the formatting (particularly the varying currencies) revert to either plain numbers of GBP.

    Does anyone know of the correct code to force VB to keep the format of the cells, be it USD, JPY etc?

    Help is much appreciated
  • albertw
    Contributor
    • Oct 2006
    • 267

    #2
    Originally posted by MAdcock
    I have created a VB code to export data from one worksheet to another, with rows deleted depending upon the value of a cell. My problem is that when this is copied and pasted to the new worksheet, the formatting (particularly the varying currencies) revert to either plain numbers of GBP.

    Does anyone know of the correct code to force VB to keep the format of the cells, be it USD, JPY etc?

    Help is much appreciated
    hi

    easiest way to find out:
    go to menu -- extra | macro | record a new macro
    then perform the exact operation how you want it done.
    close the recording.
    look back (Alt+F11) in the module how this macro was recorded
    alter anything you want diffently and use this macro anywhere else.

    Comment

    Working...