Google Sheets API v4 - 如何获得最后一行的价值? [英] Google Sheets API v4 - How to get the last row with value?

查看:20
本文介绍了Google Sheets API v4 - 如何获得最后一行的价值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在新的 Google Sheets API v4 中获取最后一行的值?

How to get the last row with value in the new Google Sheets API v4 ?

我使用它从工作表中获取范围:

i use this to get a range from a sheet:

mService.spreadsheets().values().get("ID_SHEET", "Sheet1!A2:B50").execute();

如何检测工作表中具有值的最后一行?

how to detect the last row with value in the sheet ?

推荐答案

您可以将范围设置为A2:D",这将获取工作表中的最后一个数据行.

You can set the range to "A2:D" and this would fetch as far as the last data row in your sheet.

这篇关于Google Sheets API v4 - 如何获得最后一行的价值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆