+ Reply to Thread
Results 1 to 9 of 9

Copy ignores certain columns.

  1. #1
    Forum Expert JapanDave's Avatar
    Join Date
    06-10-2008
    Location
    The grid, I got in!
    MS-Off Ver
    Excel 2010/13
    Posts
    1,696

    Copy ignores certain columns.

    Well this is the first time in many years that I am stuck.
    I am opening a file from one workbook and copying data from that workbook to the one with the macro running in it.
    So the problem is it ignores the last column data and copies the data in the next column.
    Eg, it copies the data fine until column "AI", but ignores column "AJ3:AJ64" , but show the data from "AK3:AK64". The column is not hidden and has the same formatting as all the other columns.

    I tried all the the usual methods below to no avail. I even ran a loop copying each individual cell with no luck. I ran some code to make sure the columns were visible and still nothing.
    Please Login or Register  to view this content.
    I have never seen something like this, any help would be appreciated.
    Be fore warned, I regularly post drunk. So don't take offence (too much) to what I say.
    I am the real 'Napster'
    The Grid. A digital frontier. I tried to picture clusters of information as they moved through the computer. What did they look like? Ships? motorcycles? Were the circuits like freeways? I kept dreaming of a world I thought I'd never see. And then, one day...

    If you receive help please give thanks. Click the * in the bottom left hand corner.

    snb's VBA Help Files

  2. #2
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Copy ignores certain columns.

    Not sure whether I can able to fix the issue. But just wanted to give a try...

    I just tried your code with a sample workbook and it seems to be working fine.

    I believe you have to attach the error file for testing purpose
    Attached Files Attached Files


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  3. #3
    Forum Expert JapanDave's Avatar
    Join Date
    06-10-2008
    Location
    The grid, I got in!
    MS-Off Ver
    Excel 2010/13
    Posts
    1,696

    Re: Copy ignores certain columns.

    The code is sound, which is why I am stumped. I really did not want to have to post the workbooks as they are a pain to get all the personal data out of them. But if no-one has any ideas, I will post them up.

    Dave

  4. #4
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Copy ignores certain columns.

    Just to check - you don't have hidden columns in the destination worksheet either?
    Remember what the dormouse said
    Feed your head

  5. #5
    Forum Expert JapanDave's Avatar
    Join Date
    06-10-2008
    Location
    The grid, I got in!
    MS-Off Ver
    Excel 2010/13
    Posts
    1,696

    Re: Copy ignores certain columns.

    I am creating a new sheet each time I transfer the data and from debugging there seems to be nothing like that happening.

    But even trying to get any data from a single cell in that particular column also has it pick up the data next to that cell in the next column. This is really weird.

  6. #6
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Copy ignores certain columns.

    I think we'll need the workbook then.

  7. #7
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Copy ignores certain columns.

    Hello Dave,
    As an idea, when you run these two lines using F8, stop after the first( copy line) and go back to excel and see if Range("A3:AJ64"). are highlighted with copy method. If they are, then check if there are also pasted

    Please Login or Register  to view this content.

  8. #8
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Copy ignores certain columns.

    Maybe:

    Please Login or Register  to view this content.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  9. #9
    Valued Forum Contributor
    Join Date
    03-22-2013
    Location
    Australia,NSW, Wirrimbi
    MS-Off Ver
    Excel 2013
    Posts
    1,057

    Re: Copy ignores certain columns.

    Hi..

    Are the workbooks opened in the same instance of Excel?

    This might sound silly.. but have you tried it on another PC?

+ 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. COUNTIF ignores pre zero's
    By ArnolddG in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-30-2014, 04:52 PM
  2. Textbox ignores formatting
    By steve617 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-15-2013, 05:09 PM
  3. Excel ignores format when copy via VBA
    By [email protected] in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-30-2012, 11:35 AM
  4. Replies: 2
    Last Post: 07-11-2012, 08:58 AM
  5. Min Value using array ignores Zero
    By mauddib in forum Excel General
    Replies: 2
    Last Post: 02-16-2005, 03:04 PM

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