+ Reply to Thread
Results 1 to 2 of 2

Indirect function: dragging across

  1. #1
    Registered User
    Join Date
    10-07-2019
    Location
    Belgium
    MS-Off Ver
    2016
    Posts
    2

    Indirect function: dragging across

    Hi,

    I am using an indirect function, but I want to drag the function down and across.
    Initial formula:
    =IF(Verlof!K18="VG";0;IF(Verlof!K18="Z";0;IF(Verlof!K18="HVG";0,5;IF(Verlof!K18="W";0;IF($D135="";"";IF(Verlof!K18="THD";0,5;IF(Verlof!K18="T";0;1)))))))

    To drag it down, I changed it into the following formula:

    =IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="VG";0;IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="Z";0;IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="HVG";0,5;IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="W";0;IF($D136="";"";IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="THD";0,5;IF(INDIRECT("'Verlof'!K"&ROW(Verlof!K18))="T";0;1)))))))

    But when I want to drag it across, the "K" in:'Verlof'!K, does not change to "L". the reason I am using indirect is to stick the formulas to the same cell when inserting or deleting rows.
    Can anybody help me?

    Highly appreciated.
    Last edited by Laurensvl; 11-07-2019 at 02:34 PM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,724

    Re: Indirect function: dragging across

    If you listed the values VG, Z, HVG, W, THD, and T in column A of a separate sheet (e.g. Sheet2), with the corresponding values in column B, then you could change your formula to:

    =IF($D135="";"";VLOOKUP(Verlof!K18;Sheet2!$A:$B;2;0))

    which is a lot shorter and should not depend on the insertion/deletion of rows/columns after it is copied across and down.

    Hope this helps.

    Pete

+ 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. copy/paste or dragging cells using INDIRECT in formula
    By notoriusjt2 in forum Excel General
    Replies: 31
    Last Post: 02-10-2016, 07:46 PM
  2. Replies: 16
    Last Post: 09-29-2015, 01:06 AM
  3. [SOLVED] INDIRECT Function with multiple sheets - SUMIF, INDIRECT & MATCH
    By DJDRU in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 10-07-2014, 08:42 AM
  4. Problems dragging down Indirect formula referring to a range
    By _hs_ in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 06-26-2013, 08:09 AM
  5. Dragging the Indirect Function HELP!!!
    By Mjs7985 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-22-2013, 12:22 PM
  6. Dragging down Indirect Formula
    By MROMAR in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-22-2012, 10:33 AM
  7. Held dragging INDIRECT FUNCTION
    By ChronicTiger in forum Excel General
    Replies: 4
    Last Post: 01-14-2006, 07:45 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