+ Reply to Thread
Results 1 to 6 of 6

Method not found error

  1. #1
    Forum Contributor
    Join Date
    12-11-2012
    Location
    Guadalajara, Mexico
    MS-Off Ver
    Excel 2007 & 2013
    Posts
    101

    Method not found error

    Hello I have a new issue here with my programming and wondered if anyone could help resolve the issue... My macro opens a workbook makes some changes (at least is what its supposed to do) and then copies the sheet into my Macro book but I get this error Method or data member not found in the following line:

    Please Login or Register  to view this content.
    I dont know what is wrong and need some advise. Here is the complete code.

    Please Login or Register  to view this content.

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Method not found error

    Hi, Will03,

    you should try and dim all used Variables for any routine and use Option Explicit on top of the procedure.

    You never gave any value to wsTPCC in the sniplet you posted, and according to what I guess the variable should read wbTPCC in order to make the code work. Then again, the context is not clear from the sniplet.

    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  3. #3
    Forum Contributor
    Join Date
    12-11-2012
    Location
    Guadalajara, Mexico
    MS-Off Ver
    Excel 2007 & 2013
    Posts
    101

    Re: Method not found error

    Actually I will post the whole code for better understanding hopefully it will help to clarify my issue a little better...

    Please Login or Register  to view this content.

  4. #4
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Method not found error

    Hi, Will03,

    just guessing:
    Please Login or Register  to view this content.
    Ciao,
    Holger

  5. #5
    Forum Contributor
    Join Date
    12-11-2012
    Location
    Guadalajara, Mexico
    MS-Off Ver
    Excel 2007 & 2013
    Posts
    101

    Re: Method not found error

    Still get the same error but I believe its because the sheet does not have the name yet... So confusing...

    Please Login or Register  to view this content.

  6. #6
    Forum Guru Norie's Avatar
    Join Date
    02-02-2005
    Location
    Stirling, Scotland
    MS-Off Ver
    Microsoft Office 365
    Posts
    19,644

    Re: Method not found error

    wsTPPC is declared as a worksheet, worksheets don't have a Sheets property/method.

    Also, as far as I can see, you never actually give a value to wsTPCC or assign it to reference anything.
    If posting code please use code tags, see here.

+ 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. Compile Error Method or data member not found
    By ixelister in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-23-2014, 03:39 PM
  2. [SOLVED] error: Method or Data Member not found
    By CRIMEDOG in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-26-2013, 11:01 AM
  3. Compile Error: Method of data member not found (VBA)
    By vbatech in forum Excel Programming / VBA / Macros
    Replies: 22
    Last Post: 03-14-2012, 05:37 PM
  4. Compiler error: Method or data member not found
    By sathikbabu in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-23-2011, 02:51 AM
  5. [SOLVED] Compile Error Method or data member not found
    By ExcelMonkey in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-04-2005, 06:05 PM

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