nithinmurali / pygsheets

Google Sheets Python API v4

Home Page:https://pygsheets.readthedocs.io/en/latest

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Sample for custom_formula

startupsandcode opened this issue · comments

Would love an example on how to use a custom formula over a range dynamically.

Here is my "hypothesis":

sheet.add_conditional_formatting(
[2, 2],
[sheet.rows, sheet.cols],
"CUSTOM_FORMULA",
format={
"backgroundColorStyle": {
"rgbColor": {"red": 0, "green": 1, "blue": 0}
}
},
condition_values=['=if(isnumber(),1,regexmatch(,"\d"))']
)

I'm not sure how to reference the I inserted above as it formats a range.