+ Reply to Thread
Results 1 to 12 of 12

Run time error 438, object doesnt support this property or method

  1. #1
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Run time error 438, object doesnt support this property or method

    I'm having some issues with my macro that previously worked perfectly I have no idea what is going on when I run it to consolidate my sheets named A-Z it stops after G and gives me an error that Run time error 438, This doesn't occur on my practice sheet only on my main workbook and the error is with the LR = .Cells(.Rows.Count, 8).End(xlUp).Row

    Please Login or Register  to view this content.
    Last edited by 33CDonnelly; 10-02-2013 at 11:22 AM.
    The Truth shall set you free

  2. #2
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    So basically this macro works on my practice sheet but when I apply it to my main sheet is hiccups and stops at Sheet G when consolidating sheets A-Z and gives me a runtime error - the error seems to be with this line LR = .Cells(.Rows.Count, 8).End(xlUp).Row not sure what's going on it was working yesterday on my main sheet but now it doesn't.

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

    Re: Run time error 438, object doesnt support this property or method

    LR = .Cells(.Rows.Count, 8).End(xlUp).Row
    ----------^ remove the dot (there's not Sheets.Rows property.
    Ben Van Johnson

  4. #4
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    LR = .Cells(Rows.Count, 7).End(xlUp).Row
    So like that?
    Last edited by 33CDonnelly; 09-18-2013 at 07:55 PM.

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

    Re: Run time error 438, object doesnt support this property or method

    That's it.

  6. #6
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Run time error 438, object doesnt support this property or method

    sh.rows returned valid number of rows for me.

    I would think the problem lies in the variation of data/structure in the workbook. A simple test of your code on dummy data works.
    You loop through Sheets which can include non worksheet objects, such as chart sheets which indeed do not have .Rows collection.

    maybe should change
    Please Login or Register  to view this content.
    Cheers
    Andy
    www.andypope.info

  7. #7
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    Still having issues with this one, It works when all the data is removed but for some reason something goes wrong on my active book and its still stopping after sheet G All sheets are exactly the same format so im still unsure what's going on.

  8. #8
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    So here are the 2 files, the VBA one contains my macro and I call it up in my Main sheet to consolidate the sheets. unfortunately it no longer works in the main sheet. Can someone take a crack at it and tell me what went wrong?
    Attached Files Attached Files

  9. #9
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Run time error 438, object doesnt support this property or method

    Your buggy file contains a chart sheet, which has not cells/rows/columns etc.

    loop through the worksheet rather than sheet collection
    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    that's weird, It shouldn't have any chart sheets lol. how would I delete that?

  11. #11
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,430

    Re: Run time error 438, object doesnt support this property or method

    right click a sheet tab an pick Unhide.

  12. #12
    Registered User
    Join Date
    08-13-2013
    Location
    California, USA
    MS-Off Ver
    Excel 2010
    Posts
    66

    Re: Run time error 438, object doesnt support this property or method

    your a life saver!, dunno who added that in there lol

+ 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 Error: Object doesnt support the property or method
    By AntiPivotTable in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-30-2013, 12:25 AM
  2. Object doesnt support this property or method- error
    By kiran527 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-13-2012, 09:39 AM
  3. Run-time error '438': Object doesn't support this property or method
    By s3a in forum Excel Programming / VBA / Macros
    Replies: 21
    Last Post: 11-15-2012, 11:25 AM
  4. Run-Time Error 438: Object doesn't support this property or method
    By rodrigorpinto in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 03-02-2011, 02:21 PM
  5. Run-time error '438': Object doesn't support this property or method
    By ophelia in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-23-2007, 05:27 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