+ Reply to Thread
Results 1 to 8 of 8

Paste special values from one sheet to another using VBA code in excel

  1. #1
    Registered User
    Join Date
    03-06-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    95

    Paste special values from one sheet to another using VBA code in excel

    Hi,

    I have some data in columnA (A1 to A1000) i want to copy and paste special values (column A is having some formulas) to another sheet using VBA code, and also in another sheet this 1000 cells has split in to 3 columns the cut of point is 300. I dont want to do this manually i want to do this using some Code

    example in sheet 1 Column A I have 1 to 1000 numbers (A1 to A1000) i want to copy and paste special these 1000 numbers in to sheet2 in Column A,B,C means in sheet 2 up to 300 numbers in ColumnA and from 301 to 600 in column B and 601 to 900 in column C remaining in Column D

    Thank you so much for your help

  2. #2
    Forum Expert millz's Avatar
    Join Date
    08-14-2013
    Location
    Singapore
    MS-Off Ver
    Excel, Access 2016
    Posts
    1,694

    Re: Paste special values from one sheet to another using VBA code in excel

    Try:
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    03-06-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    95

    Re: Paste special values from one sheet to another using VBA code in excel

    Thank you so much for you immediate response,

    Please tell me where I have to copy this code is it in sheet1 or sheet2

    I have a small doubt please tell me whether this code will copy and paste special as values from sheet1 to sheet2 automatically means once i will enter data in sheet1 the sheet 2 will get the paste special values from sheet1 in multiple columns with cut off each column is 300

    Thank you

  4. #4
    Forum Expert millz's Avatar
    Join Date
    08-14-2013
    Location
    Singapore
    MS-Off Ver
    Excel, Access 2016
    Posts
    1,694

    Re: Paste special values from one sheet to another using VBA code in excel

    Place it in a module. in VBE, right click on your workbook and insert -> module. Copy and paste the code in, then go to your workbook, press Alt + F8 and run it.

    Please Login or Register  to view this content.

  5. #5
    Forum Contributor
    Join Date
    09-02-2013
    Location
    Netherlands
    MS-Off Ver
    Office 365 (2013)
    Posts
    268

    Re: Paste special values from one sheet to another using VBA code in excel

    Quote Originally Posted by chavanalini View Post
    Please tell me where I have to copy this code is it in sheet1 or sheet2
    If you don't want to use a macro, use this in Sheet2.Range(A1:D300) 'if you use it beyond that range it should also work, values will be blank. Formulas will be pasted.

    Please Login or Register  to view this content.
    My advice is just to use millz VBA script

  6. #6
    Registered User
    Join Date
    03-06-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    95

    Re: Paste special values from one sheet to another using VBA code in excel

    Hi,

    formula is not working giving error,

    Thanks

  7. #7
    Forum Contributor
    Join Date
    09-02-2013
    Location
    Netherlands
    MS-Off Ver
    Office 365 (2013)
    Posts
    268

    Re: Paste special values from one sheet to another using VBA code in excel

    replace ; by ,
    Then it should work

  8. #8
    Registered User
    Join Date
    03-06-2013
    Location
    India
    MS-Off Ver
    Excel 2010
    Posts
    95

    Re: Paste special values from one sheet to another using VBA code in excel

    Thank you so much it is working

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. VBA code to open new workbook and copy and paste special values
    By oddinho2 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 08-12-2013, 11:24 PM
  2. Replies: 1
    Last Post: 12-05-2012, 11:37 AM
  3. [SOLVED] Set code copy and paste special values
    By marreco in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-25-2012, 08:52 PM
  4. [SOLVED] Code for Copy and Paste Special- Values in Columns
    By gautamacharya in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-23-2012, 04:51 PM
  5. Paste special as values code not working?
    By HelenW in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 12-05-2008, 08:03 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1