+ Reply to Thread
Results 1 to 6 of 6

Formula Insert

  1. #1
    Forum Contributor
    Join Date
    05-15-2015
    Location
    Orlando, FL
    MS-Off Ver
    Office Standard 2016
    Posts
    266

    Formula Insert

    Hi everyone,

    Can someone please tell me why I'm receiving a " 1004 - Unable to set the FormulaArray property of the Range Class " error on this:


    Please Login or Register  to view this content.

  2. #2
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    2,760

    Re: Formula Insert

    I would suggest you create a macro using the formula in a cell for two reasons, one you know you have a working formula and two you can see the string that Excel creates for the formula and maybe you will find a small syntax error.
    Click the * Add Reputation button in the lower left hand corner of this post to say thanks.

    Don't forget to mark this thread SOLVED by going to the "Thread Tools" drop down list above your first post and choosing solved.

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,621

    Re: Formula Insert

    Good news and bad news. Good news: I have created a test bed to see what is being output. Bad news: I can't overcome the problem, as yet.

    The original Array Formula does work, so I do not know why the VBA doesn't create the same formula.

    Whatever, something for you to experiment with.
    Attached Files Attached Files
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Forum Expert skywriter's Avatar
    Join Date
    06-09-2014
    Location
    USA
    MS-Off Ver
    2016
    Posts
    2,760

    Re: Formula Insert

    Quote Originally Posted by TMS View Post
    The original Array Formula does work, so I do not know why the VBA doesn't create the same formula.
    I suspect the string is exceeding the 255 character limit.

    See remarks.

  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,621

    Re: Formula Insert

    Excellent call! Well done you.

    Changing the tab name from LOG DETAILS to just LOG (which also means the single quotes can go), and taking out all the stuff I added to make it easier to read works.

    Please Login or Register  to view this content.
    Thank you. Now I can sleep tonight

  6. #6
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,621

    Re: Formula Insert

    Or, using a Named Range

    Please Login or Register  to view this content.
    Attached Files Attached Files

+ 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. [SOLVED] Trying to insert formula into cell using ActiveCell.Formula but receiving run-time error
    By rbaxter89 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-28-2022, 04:33 PM
  2. Replies: 0
    Last Post: 05-05-2021, 12:36 AM
  3. To Find and Insert column and add Formula and copy formula down
    By Akatecho in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-27-2014, 11:52 PM
  4. Replies: 1
    Last Post: 02-02-2013, 02:28 PM
  5. excel formula calculation - how to insert the right formula
    By Manila.Boracay in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 11-17-2011, 04:21 AM
  6. Insert excel formula using VBA......MATCH function is what i want to insert
    By welchs101 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 05-07-2009, 07:31 PM
  7. Insert row insert formula
    By PhilH1982 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-28-2008, 03:13 PM

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