+ Reply to Thread
Results 1 to 3 of 3

Valid Excel formula not working in macro

  1. #1
    Registered User
    Join Date
    04-22-2013
    Location
    In the lab...
    MS-Off Ver
    Excel 2010
    Posts
    12

    Valid Excel formula not working in macro

    Greetings,

    I'm trying to insert a formula (is valid; have used in an Excel sheet previously - also, have set Formulas - Calculation Options to Automatic) into a particular cell using the macro shown below, but I keep getting a "Compile error, Syntax error" as though there's something wrong with the formula. Are there certain formulas that cannot be used in a macro?

    (Note: Although the Excel formula uses double quotation marks around the "Item" bit, I tried using single quotation marks (as in 'Item'), but get "Run time error '1004': Application-defined or object-defined error".)

    Please Login or Register  to view this content.
    Thanks in advance...

    Nikolette

  2. #2
    Forum Guru
    Join Date
    08-15-2004
    Location
    Tokyo, Japan
    MS-Off Ver
    2013 O.365
    Posts
    22,666

    Re: Valid Excel formula not working in macro

    You need to add another double quotation when used in a formula
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    04-22-2013
    Location
    In the lab...
    MS-Off Ver
    Excel 2010
    Posts
    12

    Re: Valid Excel formula not working in macro

    That worked! Thanks so much

+ 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