Kald af Calc-funktioner

Udover de medfĂždte BASIC-funktioner kan du kalde Calc-funktioner i dine makroer og scripts.

Kalde interne Calc-funktioner i Basic

Brug funktionen CreateUNOService til at tilgÄ tjenestencom.sun.star.sheet.FunctionAccess.

Eksempel:


    REM Koden herunder virker ikke pÄ tillÊgsfunktioner, som har en anden kald-procedure.
    Function MyVlook(item, InRange As Object, FromCol As Integer)
        Dim oService As Object
        oService = createUnoService("com.sun.star.sheet.FunctionAccess")
        REM Brug altid det engelske funktionsnavn
        MyVlook = oService.callFunction("VLOOKUP",Array(item, InRange, FromCol, True))
    End Function

Kald af Calc-tillĂŠgsfunktioner i BASIC

Calcs tillĂŠgsfunktioner findes i tjenesten com.sun.star.sheet.addin.Analysis.

Eksempel:


REM Eksempel pÄ kald af tillÊgsfunktionen SQRTPI
Funktionen MySQRTPI(arg som dobbelt) som dobbelt
   Dim oService as Object
   oService = createUNOService("com.sun.star.sheet.addin.Analysis")
   MySQRTPI = oService.getSqrtPi(arg)
End Function

Calc Function name

UNO service name

PÅLØBRENTE

com.sun.star.sheet.addin.Analysis.getAccrint

PÅLØBRENTE.UDLØB

com.sun.star.sheet.addin.Analysis.getAccrintm

AMORDEGRC

com.sun.star.sheet.addin.Analysis.getAmordegrc

AMORLINC

com.sun.star.sheet.addin.Analysis.getAmorlinc

BESSELI

com.sun.star.sheet.addin.Analysis.getBesseli

BESSELJ

com.sun.star.sheet.addin.Analysis.getBesselj

BESSELK

com.sun.star.sheet.addin.Analysis.getBesselk

BESSELY

com.sun.star.sheet.addin.Analysis.getBessely

BIN.TIL.DEC

com.sun.star.sheet.addin.Analysis.getBin2Dec

BIN2HEX

com.sun.star.sheet.addin.Analysis.getBin2Hex

BIN.TIL.OKT

com.sun.star.sheet.addin.Analysis.getBin2Oct

COMPLEX

com.sun.star.sheet.addin.Analysis.getComplex

CONVERT

com.sun.star.sheet.addin.Analysis.getConvert

KUPONDAGE.SA

com.sun.star.sheet.addin.Analysis.getCoupdaybs

KUPONDAGE.A

com.sun.star.sheet.addin.Analysis.getCoupdays

KUPONDAGE.ANK

com.sun.star.sheet.addin.Analysis.getCoupdaysnc

KUPONDAG.NÆSTE

com.sun.star.sheet.addin.Analysis.getCoupncd

KUPONBETALINGER

com.sun.star.sheet.addin.Analysis.getCoupnum

KUPONDAG.FORRIGE

com.sun.star.sheet.addin.Analysis.getCouppcd

AKKUM.RENTE

com.sun.star.sheet.addin.Analysis.getCumipmt

AKKUM.HOVEDSTOL

com.sun.star.sheet.addin.Analysis.getCumprinc

DEC.TIL.BIN

com.sun.star.sheet.addin.Analysis.getDec2Bin

DEC.TIL.HEX

com.sun.star.sheet.addin.Analysis.getDec2Hex

DEC.TIL.OKT

com.sun.star.sheet.addin.Analysis.getDec2Oct

DELTAB

com.sun.star.sheet.addin.Analysis.getDelta

DISKONTO

com.sun.star.sheet.addin.Analysis.getDisc

KR.DECIMAL

com.sun.star.sheet.addin.Analysis.getDollarde

KR.BRØK

com.sun.star.sheet.addin.Analysis.getDollarfr

VARIGHED

com.sun.star.sheet.addin.Analysis.getDuration

EDATO

com.sun.star.sheet.addin.Analysis.getEdate

EFFEKTIV.RENTE

com.sun.star.sheet.addin.Analysis.getEffect

SLUT.PÅ.MÅNED

com.sun.star.sheet.addin.Analysis.getEomonth

FEJLFUNK

com.sun.star.sheet.addin.Analysis.getErf

FEJLFUNK.KOMP

com.sun.star.sheet.addin.Analysis.getErfc

DOBBELT.FAKULTET

com.sun.star.sheet.addin.Analysis.getFactdouble

FVTABEL

com.sun.star.sheet.addin.Analysis.getFvschedule

STØRSTE.FÆLLES.DIVISOR

com.sun.star.sheet.addin.Analysis.getGcd

GETRIN

com.sun.star.sheet.addin.Analysis.getGestep

HEX.TIL.BIN

com.sun.star.sheet.addin.Analysis.getHex2Bin

HEX.TIL.DEC

com.sun.star.sheet.addin.Analysis.getHex2Dec

HEX.TIL.OKT

com.sun.star.sheet.addin.Analysis.getHex2Oct

IMAGABS

com.sun.star.sheet.addin.Analysis.getImabs

IMAGINÆRDEL

com.sun.star.sheet.addin.Analysis.getImaginary

IMARGUMENT

com.sun.star.sheet.addin.Analysis.getImargument

IMAGKONJUGERE

com.sun.star.sheet.addin.Analysis.getImconjugate

IMAGCOS

com.sun.star.sheet.addin.Analysis.getImcos

IMAGCOSH

com.sun.star.sheet.addin.Analysis.getImcosh

IMAGCOT

com.sun.star.sheet.addin.Analysis.getImcot

IMAGCSK

com.sun.star.sheet.addin.Analysis.getImcsc

IMAGCSKH

com.sun.star.sheet.addin.Analysis.getImcsch

IMAGDIV

com.sun.star.sheet.addin.Analysis.getImdiv

IMAGEKSP

com.sun.star.sheet.addin.Analysis.getImexp

IMAGLN

com.sun.star.sheet.addin.Analysis.getImln

IMAGLOG10

com.sun.star.sheet.addin.Analysis.getImlog10

IMAGLOG2

com.sun.star.sheet.addin.Analysis.getImlog2

IMAGPOTENS

com.sun.star.sheet.addin.Analysis.getImpower

IMAGPRODUKT

com.sun.star.sheet.addin.Analysis.getImproduct

IMAGREELT

com.sun.star.sheet.addin.Analysis.getImreal

IMAGSEK

com.sun.star.sheet.addin.Analysis.getImsec

IMAGSEKN

com.sun.star.sheet.addin.Analysis.getImsech

IMSIN

com.sun.star.sheet.addin.Analysis.getImsin

IMAGSINH

com.sun.star.sheet.addin.Analysis.getImsinh

IMAGKVROD

com.sun.star.sheet.addin.Analysis.getImsqrt

IMAGSUB

com.sun.star.sheet.addin.Analysis.getImsub

IMAGSUM

com.sun.star.sheet.addin.Analysis.getImsum

IMAGTAN

com.sun.star.sheet.addin.Analysis.getImtan

RENTEFOD

com.sun.star.sheet.addin.Analysis.getIntrate

ER.LIGE

com.sun.star.sheet.addin.Analysis.getIseven

ER.ULIGE

com.sun.star.sheet.addin.Analysis.getIsodd

MINDSTE.FÆLLES.MULTIPLUM

com.sun.star.sheet.addin.Analysis.getLcm

MVARIGHED

com.sun.star.sheet.addin.Analysis.getMduration

MAFRUND

com.sun.star.sheet.addin.Analysis.getMround

MULTINOMIAL

com.sun.star.sheet.addin.Analysis.getMultinomial

ANTAL_ARBEJDSDAGE

com.sun.star.sheet.addin.Analysis.getNetworkdays

NOMINEL

com.sun.star.sheet.addin.Analysis.getNominal

OKT.TIL.BIN

com.sun.star.sheet.addin.Analysis.getOct2Bin

OKT.TIL.DEC

com.sun.star.sheet.addin.Analysis.getOct2Dec

OKT.TIL.HEX

com.sun.star.sheet.addin.Analysis.getOct2Hex

ULIGE.KURS.PÅLYDENDE

com.sun.star.sheet.addin.Analysis.getOddfprice

ULIGE.FØRSTE.AFKAST

com.sun.star.sheet.addin.Analysis.getOddfyield

ULIGE.SIDSTE.KURS

com.sun.star.sheet.addin.Analysis.getOddlprice

ULIGE.SIDSTE.AFKAST

com.sun.star.sheet.addin.Analysis.getOddlyield

KURS

com.sun.star.sheet.addin.Analysis.getPrice

KURS.DISKONTO

com.sun.star.sheet.addin.Analysis.getPricedisc

KURS.UDLØB

com.sun.star.sheet.addin.Analysis.getPricemat

KVOTIENT

com.sun.star.sheet.addin.Analysis.getQuotient

SLUMPMELLEM

com.sun.star.sheet.addin.Analysis.getRandbetween

MODTAGET.VED.UDLØB

com.sun.star.sheet.addin.Analysis.getReceived

SERIESUM

com.sun.star.sheet.addin.Analysis.getSeriessum

KVRODPI

com.sun.star.sheet.addin.Analysis.getSqrtpi

TBILLEQ

com.sun.star.sheet.addin.Analysis.getTbilleq

STATSOBLIGATION.KURS

com.sun.star.sheet.addin.Analysis.getTbillprice

STATSOBLIGATION.AFKAST

com.sun.star.sheet.addin.Analysis.getTbillyield

UGE.NR

com.sun.star.sheet.addin.Analysis.getWeeknum

ARBEJDSDAG

com.sun.star.sheet.addin.Analysis.getWorkday

INTERN.RENTE

com.sun.star.sheet.addin.Analysis.getXirr

NETTO.NUTIDSVÆRDI

com.sun.star.sheet.addin.Analysis.getXnpv

ÅR.BRØK

com.sun.star.sheet.addin.Analysis.getYearfrac

AFKAST

com.sun.star.sheet.addin.Analysis.getYield

AFKAST.DISKONTO

com.sun.star.sheet.addin.Analysis.getYielddisc

AFKAST.UDLØBSDATO

com.sun.star.sheet.addin.Analysis.getYieldmat


StĂžt os venligst!