I am looking for a formula:
=A2
because column A could be moved to another columnI am trying to use named range to do this. I have created a named range( teacher_Names
) for A1:A. It is not hard to get the value using app script
function getTeacherNameOnTheSameRow(row) {
let ss = SpreadsheetApp.getActive();
let values = ss.getRangeByName('teacher_Names').getValues();
return values[row-1];
}
I can just put =getTeacherNameOnTheSameRow(Row())
in cells in Column C, and no matter which column I move column A to, it will work.
My question is, is there a way to do this without app script?
I believe your current situation and goal as follows.
teacher_Names
. In this case, how about the following formula?
Please put the following formula to the column "C". By this, the column "A" of the named range teacher_Names
is retrieved with the same row.
=teacher_Names
Result:
=ARRAYFORMULA(teacher_Names)
to the cell "C1", you can see the values of the column "A" to the column "C".
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.