我正在尝试使用google script将公式设置为单元格,但它不起作用。我有几个条件和双引号,不知道如何添加双引号到工作表。
=if(B17<>"",IF(Form!B8 = "","",IF(Form!B8 = "Representative",index(House!A:H,MATCH(B17,House!G:G,0),8),index(House!A:H,MATCH(B17,Senate!G:G,0),8))),"")
如何将此公式添加到单元格?
发布于 2013-04-07 01:57:46
你有没有试过简单地用单引号把它括起来?
如下所示:(更新范围值)
sheet.getRange(1,1).setFormula('=if(B17<>"",IF(Form!B8 = "","",IF(Form!B8 = "Representative",index(House!A:H,MATCH(B17,House!G:G,0),8),index(House!A:H,MATCH(B17,Senate!G:G,0),8))),"")')
https://stackoverflow.com/questions/15853960
复制相似问题