我正在努力编写代码,发现我是谷歌表的第一个空行.
我正在使用github.com/burnash/gspread的gspread包
如果有人可以帮助我会很高兴:)
我目前刚刚导入了模块并打开了工作表
scope = ['https://spreadsheets.google.com/feeds']
credentials = ServiceAccountCredentials.from_json_keyfile_name('ddddd-61d0b758772b.json', scope)
gc = gspread.authorize(credentials)
sheet = gc.open("Event Discovery")
ws = sheet.worksheet('Event Discovery')
Run Code Online (Sandbox Code Playgroud)
我想找到行1158,它是带有函数的工作表的第一个空行,这意味着每次填充旧的空行时,它将找到下一个空行. 请参阅此处
我有一个这样的字典:
dic = {'2017-08-11': {'Yes': 157, 'Not sure': 2, 'No': 1}, '2017-08-22': {'Yes': 142, 'Not sure': 12}, '2017-08-01': {'Yes': 112, 'Others': 10, 'Not sure': 4, 'No': 9}, '2017-08-17': {'Yes': 117, 'No': 12, 'Not sure': 11, 'Others': 2}, '2017-08-25': {'Yes': 61, 'Not sure': 9}, '2017-08-23': {'Yes': 268, 'Not sure': 20, 'No': 1}, '2017-07-10': {'Yes': 123, 'Not sure': 4, 'No': 1}, '2017-08-10': {'Yes': 343, 'Not sure': 20}, '2017-07-13': {'Yes': 116, 'Others': 1, 'Not sure': 14, 'No': 2}, '2017-07-14': {'Yes': 255, 'Not sure': …Run Code Online (Sandbox Code Playgroud)