Why does this macro not reach out beyond Column O?

  • This macro doesn't error, but why does it reach out ONLY to column O, even if columns contain data?


    This one works below, but I have to hard code how many columns I want it to run on.



  • Re: Why does this macro not reach out beyon Columnn O?


    [cp]*[/cp]

    Ali :)


    Enthusiastic self-taught user of MS Excel who's always learning!
    If anyone has helped you towards solving a problem, then you can thank them by clicking on the like icon bottom right.

    :!:Forum Rules

  • Re: Why does this macro not reach out beyon Columnn O?


    Gee thanks for taking that time.


    I ALWAYS post the answer, whether I got any response or not.



    This will find the last column with data in it, vs. stopping at the last header row! That was it! I didn't even notice because technically I wasn't using headers though there was data in row 1.


  • Re: Why does this macro not reach out beyon Columnn O?


    The answer was provided here: https://www.mrexcel.com/forum/…-out-beyon-columnn-o.html


    In future, if you post on more than one forum, make sure to provide links. The rule is the same on most forums, and on both forums where you cross-posted yesterday, for the reasons outlined above.


    This forums rules are here (note the forum etiquette section): http://www.ozgrid.com/forum/misc.php?do=showrules

    Ali :)


    Enthusiastic self-taught user of MS Excel who's always learning!
    If anyone has helped you towards solving a problem, then you can thank them by clicking on the like icon bottom right.

    :!:Forum Rules

  • Re: Why does this macro not reach out beyon Columnn O?


    Yes, yes, got it.


    It's more important to insure I provide the solution wherever the help came from and almost never abandon a post. This is important to me because I know both sites we use are well indexed in the engines and this insures helping as many others as possible with similar issues/questions. That said, I'll work on providing the link. :smash:


    Quote from AliGW;788417

    The answer was provided here: https://www.mrexcel.com/forum/…-out-beyon-columnn-o.html


    In future, if you post on more than one forum, make sure to provide links. The rule is the same on most forums, and on both forums where you cross-posted yesterday, for the reasons outlined above.


    This forums rules are here (note the forum etiquette section): http://www.ozgrid.com/forum/misc.php?do=showrules

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!