VBA does not support Polish formula names, only their English equivalents.
The easiest way to do this is to turn on the macro recorder, enter the formula in Excel, and finish recording. Then you go Alt + F11 into the code, enter the module and find the last macro recorded. From it you copy the mentioned formula, possibly correcting its arguments.
By default, the recorder registers the formula in the R1C1 format - in the R code is the current row, C - the current column. If you enter the formula into cell B3, the formula: "= RC" means "= B3"
The equivalent of dollars (absolute reference) in the formula is the number next to R or C, which is "= R2C5" (which translates directly as: second row, fifth column) corresponds to "= $ E $ 2".
The equivalent of a relative reference (without dollars - moved when dragging) - is specifying a positive or negative number for R and / or C, meaning by how much the reference should be moved relative to the current one, e.g. for the mentioned B3 formula: "= R [1] C" means " = B4 ", the formula" = R [-2] C [-1] "means" = A1 "," = R [3] C [2] "means" = D6 "etc.
You insert a formula by means of a cell reference (or precede it with the name of a sheet from the Worksheets collection):
You can also use letter designations of cells, but then the assignment method changes:
You must also remember that if you are inside a quotation mark, if you want to put a single quotation mark: ", you must precede it with the second one, ie write" ".
Additionally, all semicolons separating arguments in functions in Excel are converted into commas in VBA.
So finally your example function written in letter format should look like this:
and in the R1C1 format - here it depends on which cell you are inserting it into, let's assume that in A1, like this:
greetings