问题描述
我一直在研究 FormulaR1C1 作为一个功能,这是如何正常工作的?我明白在互联网上已经说过的是第1列第1列,但是人们怎么才能使它工作?使用 FormulaR1C1 的最终结果是什么?
I have been looking at FormulaR1C1 as a function, how does this exactly work? I understand what has been said all over the internet which is stands as Row 1 Column 1, but how do people actually make it work? What is the end result of using FormulaR1C1?
还可以将其更改为从特定点开始一张表,还是一直是R1C1?那么公式R2C3可以是吗?
Also can it be changed to start at a specific point in a sheet, or it always going to be R1C1? So could it be FormulaR2C3?
推荐答案
FormulaR1C1与Formula相同,只使用R1C1样式注释,而不是A1注释。在A1注释中,您将使用:
FormulaR1C1 has the same behavior as Formula, only using R1C1 style annotation, instead of A1 annotation. In A1 annotation you would use:
Worksheets("Sheet1").Range("A5").Formula = "=A4+A10"
在R1C1中,您将使用:
In R1C1 you would use:
Worksheets("Sheet1").Range("A5").FormulaR1C1 = "=R4C1+R10C1"
它不对行1列1起作用,它作用于目标单元格或范围。列1与列A相同,因此R4C1与A4相同,R5C2是B5等等。
It doesn't act upon row 1 column 1, it acts upon the targeted cell or range. Column 1 is the same as column A, so R4C1 is the same as A4, R5C2 is B5, and so forth.
该命令不更改名称,目标单元格变化。对于您的R2C3(也称为C2)示例:
The command does not change names, the targeted cell changes. For your R2C3 (also known as C2) example :
Worksheets("Sheet1").Range("C2").FormulaR1C1 = "=your formula here"
这篇关于FormulaR1C1的功能是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!