+ Reply to Thread
Results 1 to 4 of 4

Array to Range Questions

  1. #1
    Registered User
    Join Date
    04-26-2020
    Location
    Greater Atlanta Metro
    MS-Off Ver
    2016 Pro Plus
    Posts
    17

    Question Array to Range Questions

    I have the code below which pulls two columns into an array and then moves those into a destination sheet. Two issues I'm hoping for help to solve: 1)How do I set the source range to skip the header row? 2)How do I set it to paste the values into the first blank row on the destination sheet?


    Please Login or Register  to view this content.

  2. #2
    Forum Expert Keebellah's Avatar
    Join Date
    01-12-2014
    Location
    The Netherlands
    MS-Off Ver
    Office 2021 (Windows)
    Posts
    7,905

    Re: Array to Range Questions

    Hi, weel, VBA and the code is just 'dumb code', what I mean to say is, it does exactly what YOU tell it to do.
    If you do not want the header row, the you you have to 'tell the code' where the header row is and (eg: you can set a constant hrow with the row) and start from the first row under that row
    The first blank row, well, the same story, YOU 'tell the code' which row is last filled row, you can calculate that using simple vba code and set that up ws the starting row eg LastRow) and start from there
    This means your code needs some minor modifications but I'm sure you can pick it up from here

    probably something like this:

    Please Login or Register  to view this content.
    This was typed without testing in Excel so maybe a syntax error but this is the idea
    ---
    Hans
    "IT" Always crosses your path!
    May the (vba) code be with you... if it isn't; start debugging!
    If you like my answer, Click the * below to say thank-you

  3. #3
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,607

    Re: Array to Range Questions

    Please Login or Register  to view this content.
    Ben Van Johnson

  4. #4
    Registered User
    Join Date
    04-26-2020
    Location
    Greater Atlanta Metro
    MS-Off Ver
    2016 Pro Plus
    Posts
    17

    Re: Array to Range Questions

    I had tried a variant of that and had the syntax off. Thanks for showing me where it went wrong!

+ 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. [SOLVED] Array/range operations questions
    By martix in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-14-2018, 11:25 AM
  2. Array handling questions
    By James McMurray in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-22-2008, 11:19 PM
  3. array questions
    By Gary Keramidas in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-01-2005, 03:15 AM
  4. [SOLVED] Array questions
    By Perico in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-01-2005, 04:05 PM
  5. [SOLVED] Determining number of values in an array (2 related questions)
    By KR in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-04-2005, 06:06 PM
  6. Array Functions - Two Questions
    By MDW in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 01-12-2005, 03:06 PM
  7. [SOLVED] Making progress with array functions, another two questions
    By Don Taylor in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-04-2005, 05:06 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