Dokumentace/Výpočetní funkce/NEPŘÍMÉ

    From The Document Foundation Wiki
    This page is a translated version of the page Documentation/Calc Functions/INDIRECT and the translation is 42% complete.
    Other languages:


    Název funkce:

    INDIRECT

    Kategorie:

    Tabulkový procesor

    Shrnutí:

    Tvoří reference založenou na string reprezentaci toho odkazu. Odkaz může být v samostatné buňce nebo v souboru buněk a volitelně může obsahovat také pracovní list, s nebo bez názvu souboru.

    Volitelný argument kontroluje, jestli input řetězec používá Calc A1 nebo Excel R1C1 vzorec syntaxe. ( podívejte se na Formula stránku nápovědy s podrobnostmi).

    Funkce ADDRESS se používá k dynamickému určení zájmové buňky formou textového řetězce. Výsledný řetězes může být přesunut do funkce INDIRECT načtení obsahu buňky. Nicméně, řetězec přesunutý do INDIRECT může být vytvořen/postaven pomocí jiných metod, není nutné ho vytvářet pomocí funkce ADDRESS.

    Syntaxe:

    INDIRECT(Odkaz[; A1])

    Vrátí:

    Navrací odkaz reference do jedné nebo více buněk založené na daném argumentu.

    Argumenty:

    Odkaz je textový řetězec nebo odkaz na buňku obsahující textový řetězec, který reprezentuje odkaz.

    A1 je logická hodnota nebo odkaz k buňce obsahující logickou hodnotu, která určuje vzorec syntaxe, která by měla být použita v návratném řetězci. Pokud A1 je nastaven na 0 nebo FALSE, je použit vzorec syntaxe Excel R1C1.

    • Pokud A1 je nečíselný (nelogický), tak INDIRECT hlásí #VALUE! chybu.
    • Pokud kombinace odkazu a A1 argumentů nesouhlasí s platným odkazem, tak INDIRECT hlásí #REF! chybu.
    • Pokud funkce INDIRECT náleží externímu odkazu, můžete obdržet vhodnou zprávu ohledně otevření vaší tabulky upozorňující, že automatické ukládání externích odkazů je zakázáno. Ve stejnou chvílí se objeví Chyba:540 v zasažené buňce. Klikněte na tlačítko Allow updating abyste zapnuli obnovování těchto odkazů.

    Další detaily:

    • INDIRECT je proměnlivá funkce. To znamená, že výpočet aktualizuje odkaz navrácený INDIRECT kdy jakákoliv any buňka je aktualizována výběrem Data ▸ Calculate ▸ Recalculate , stisknutím klávesy F9 nebo při jakékoliv vstupní události.
    • Výpočty funkcí ADDRESS a INDIRECT si blízce spjaté. ADDRESS navrací odkaz buňky jako text, který může být přesunut jako argument INDIRECT k načtení obsahu odkazované buňky.
    • Pokud přesunete řetězec do INDIRECT, který byl vytvrořen z ADDRESS, ujistěte se, že tyto dvě funkce použijí stejné nastavení pro A1 argument. Pokud tyto dvě funkce předpokládají rozdílný vzorec syntaxe, výsledkem může být chyba.
    • In versions of the ODF prior to 1.2, the specification for the INDIRECT function did not include the A1 argument to differentiate between Calc A1 and Excel R1C1 formula syntax. When saving a document in ODF 1.0/1.1 format, calls to the INDIRECT function are saved without conversion. This may lead to subsequent errors appearing for those function calls.
    • Microsoft Excel represents some cell references differently than Calc, so this function is not always portable. For example, the formula =INDIRECT("Sheet2.A1") is valid in Calc (where the worksheet name separator is the dot "."), but the form required in Excel is =INDIRECT("Sheet2!A1") (where the worksheet name separator is the exclamation mark "!").
    • If you open an Excel spreadsheet that uses indirect addresses calculated from string functions, the sheet addresses will not be translated automatically. For example, the Excel address in =INDIRECT("'[filename]sheetname'!"&B1) is not converted into the Calc address in =INDIRECT("'filename#sheetname'."&B1).

    Příklady:

    Data for examples
    A B C D
    1 1 2 6 =INDIRECT("R[2]C[-1]"; 0)
    2 3 4 5
    3 7 B2
    4 "myCellRange": A1:B2   named range
    Vzorec Popis Vrátí
    =INDIRECT("B2") Equivalent to =B2. Note the use of quotation marks, enclosing a text string. 4
    =INDIRECT("B" & "2") Equivalent to =B2. 4
    =INDIRECT(D3) Equivalent to =B2. Note the lack of quotation marks; the argument is a cell reference. 4
    =INDIRECT(B2) Note the lack of quotation marks. Since the referenced cell does not contain a text string representing a cell address, the result is an error. #REF!
    =INDIRECT("B2"; 99) Equivalent to =B2. The A1 argument is a non-zero numeric value, equivalent to omited. 4
    =SUM(INDIRECT("A1:B2")) First return a reference to the cell range A1:B2; the formula therefore returns the sum of the four numbers in these cells. 10
    =SUM(INDIRECT("myCellRange")) First return a reference to the cell range A1:B2; the formula therefore returns the sum of the four numbers in these cells. 10
    =INDIRECT("R2C3"; 0) Note the use of quotation marks, enclosing a text string, and value zero for the A1 argument. Return the contents of cell R2C3 (C2). 5
    =INDIRECT("R[2]C[-1]"; 0)

    where the formula is entered in cell D1.

    The A1 argument is 0, so R[2]C[-1] is evaluated in R1C1-formula syntax, in this case relative to cell D1; 2 rows down and -1 column across, so as to yield a reference to cell C3. 7
    =SUM(INDIRECT("a1:" & ADDRESS(1;3))) Sum the cells in the range from cell A1 to the cell whose address is defined by row 1 and column 3 (C1). 9

    Související funkce LibreOffice:

    ADDRESS

    COLUMN

    ROW

    ODF standard:

    Související (nebo podobné) funkce Excelu:

    INDIRECT