+ Reply to Thread
Results 1 to 7 of 7

Search column "header" an print the entire column in another worksheet

  1. #1
    Registered User
    Join Date
    04-02-2012
    Location
    Brasil
    MS-Off Ver
    Excel 2010
    Posts
    20

    Question Search column "header" an print the entire column in another worksheet

    Hi

    I have some logs with alot of columns (range A5:CQ:5), I need to read this range, and if it have some value print the entire column on another worksheet.
    e.g.


    Please Login or Register  to view this content.
    Let's say I only need the columns "File" and "Point Number" to be printed on another worksheet named "Result", my idea was something like this

    Please Login or Register  to view this content.

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Search column "header" an print the entire column in another worksheet

    Try this

    Please Login or Register  to view this content.
    Martin

  3. #3
    Registered User
    Join Date
    04-02-2012
    Location
    Brasil
    MS-Off Ver
    Excel 2010
    Posts
    20

    Re: Search column "header" an print the entire column in another worksheet

    Thanks for the reply.
    If I run this code I get runtime error 9.
    Dont know if its right but I changed "Destination:=Sheets("Select")" to "Destination:=Sheets("Result")" and now I get runtime error 1004

  4. #4
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Search column "header" an print the entire column in another worksheet

    You made a correct change - sorry for my mistake. When you get the error, which line is highlighted in yellow when you hit the debug button?

  5. #5
    Registered User
    Join Date
    04-02-2012
    Location
    Brasil
    MS-Off Ver
    Excel 2010
    Posts
    20

    Re: Search column "header" an print the entire column in another worksheet

    The line is
    Please Login or Register  to view this content.
    Last edited by CassioGodinho; 04-22-2012 at 12:19 PM.

  6. #6
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Search column "header" an print the entire column in another worksheet

    OK - I can see the problem.

    Please replace with

    Please Login or Register  to view this content.

  7. #7
    Registered User
    Join Date
    04-02-2012
    Location
    Brasil
    MS-Off Ver
    Excel 2010
    Posts
    20

    Re: Search column "header" an print the entire column in another worksheet

    Thanks man, I just made it work using a less elegant aproach.
    Please Login or Register  to view this content.
    Thats ugly code but aparently worked haha

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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