+ Reply to Thread
Results 1 to 8 of 8

VBA Error

  1. #1
    Forum Contributor
    Join Date
    11-14-2009
    Location
    Midwest
    MS-Off Ver
    Excel 2003/2007
    Posts
    103

    VBA Error

    I have a macro that runs well until it hits this line
    Please Login or Register  to view this content.
    Then I get a Run time error 438 - Object doesn't support this property or method.

    Anyone know what I'm doing wrong here?
    Last edited by bibleguy125; 02-15-2012 at 12:59 PM.

  2. #2
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: VBA Error

    You've spelt Formula wrong.

    Dom
    "May the fleas of a thousand camels infest the crotch of the person who screws up your day and may their arms be too short to scratch..."

    Use code tags when posting your VBA code: [code] Your code here [/code]

    Remember, saying thanks only takes a second or two. Click the little star to give some Rep if you think an answer deserves it.

  3. #3
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,352

    Re: VBA Error

    Looks ok to me, but I'm a little dyslectic. It is that darn VB Editor has all these reserved words and knows how to spell.
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  4. #4
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: VBA Error

    Pesky marcos

    Dom

  5. #5
    Forum Contributor
    Join Date
    11-14-2009
    Location
    Midwest
    MS-Off Ver
    Excel 2003/2007
    Posts
    103
    Wow, that is awesome. Thanks for catching it. I probably would have missed that for a long time.

  6. #6
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200

    Re: VBA Error

    Debugging and using Option Explicit would have highlighted the error
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

  7. #7
    Forum Contributor
    Join Date
    11-14-2009
    Location
    Midwest
    MS-Off Ver
    Excel 2003/2007
    Posts
    103

    Re: VBA Error

    It highlighted it when I debugged, but it was the whole line and I still missed the fact that I had misspelled formula. I changed it this morning and everything works great.

  8. #8
    Forum Expert Domski's Avatar
    Join Date
    12-14-2009
    Location
    A galaxy far, far away
    MS-Off Ver
    Darth Office 2010
    Posts
    3,950

    Re: VBA Error

    As Roy suggests though having Option Explicit set would have prevented such misspelling and highlighted the problem for you as you entered your code. Not only that but it forces you to declare any variables that you might be using which is also good practise.

    Dom

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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