+ Reply to Thread
Results 1 to 4 of 4

Formula with Macro not pasted complete, ' missing

  1. #1
    Registered User
    Join Date
    05-31-2012
    Location
    Groenlo, Netherlands
    MS-Off Ver
    Excel 2019
    Posts
    63

    Formula with Macro not pasted complete, ' missing

    When using the following code:

    [K6].Formula = _
    "=VERGELIJKEN(J6,'Basiskalk.'!B:B,0)"

    the formula is pasted as: =VERGELIJKEN(J6,Basiskalk.!B:B,0)

    How to get the ' pasted as well?

  2. #2
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Formula with Macro not pasted complete, ' missing

    If I understood you correctly, as far as I know, the single quotation mark ' is used to reference the sheet name in the formula when your referenced sheet name consists of multiple words (more than one word) or one word with leading or trailing spaces in the sheet name.
    So if your sheet name consists of a single word without any extra space and you use a single quotation mark in the formula, the formula will auto correct it and remove the single quotation mark since it is unnecessary.
    You may try this on your sheet by manually writing the formula in K6 once with quotation marks and once with without quotation marks and you will find the formula in the cell without quotation marks.

    Does this help?
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  3. #3
    Registered User
    Join Date
    05-31-2012
    Location
    Groenlo, Netherlands
    MS-Off Ver
    Excel 2019
    Posts
    63

    Re: Formula with Macro not pasted complete, ' missing

    after giving an Enter it indeed worked. Solution is simpler than I thought.

    Use the following code now:
    [K6].FormulaR1C1 = "=MATCH(RC[-1],Basiskalk.!C[-9],0)"

    Then it works straight away

  4. #4
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,648

    Re: Formula with Macro not pasted complete, ' missing

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. Consolidating missing data across multiple rows into one complete row
    By pilboroughv in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 11-19-2014, 07:05 AM
  2. Complete Missing Row Data based on Row above
    By SamLN in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 09-22-2014, 04:54 AM
  3. Macros/Finding missing and complete addresses
    By tutv088 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-12-2014, 12:27 PM
  4. Some copied cells are missing when pasted
    By paulkaye in forum Excel General
    Replies: 3
    Last Post: 07-01-2013, 03:38 AM
  5. Find and complete missing times in a huge list
    By Jessica.Bush in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 01-05-2011, 08:34 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