Closed FarsFuad closed 4 years ago
I found the error, its because the 'allrows' method gets the length of the worksheet rows , one time only, and it never update its length , unless u uninstall the app and reinstall it again , or try hot restart button , and the only way to avoid it now , is to add 1000 empty rows and hope the user doesn't reach 1000 rows by the time.
so can u please sir make the 'allrows' updates its length every time it runs like other method do !
'row' & 'column' ...
and thanks for your time <3
Amazing Pug <3
Here u can see, the 'allrows' method length will always stay 2 , and never updates again, even if u add new empty row to the worksheet.
And here , u have the limit of 1000 rows , before the user most reinstall the app to fix it.
Hi @FarsFuad
Thanks for feedback, I'm looking into it right now.
@FarsFuad I rolled out pre-release version that fixes it, can you please check and let me know if it solved:
dependencies:
gsheets: ^0.2.5-dev.1
Regarding refresh
method - i think it was not clear how it works so i refactored it.
Before you should be doing:
// getting worksheet
var sheet = ss.worksheetByTitle('example');
// refreshing
await ss.refresh();
// getting refreshed worksheet
sheet = ss.worksheetByTitle('example');
Now you should be doing:
// getting worksheet
var sheet = ss.worksheetByTitle('example');
// refreshing
await ss.refresh();
// that's it, sheet is refreshed as well
hey , thanks for the reply Alright , let me check it out
Thanks !
Fixed ! Thank you very much sir , now i can work with allrows without any problems <3 Hope u the best <3
And i will like to see more features coming to this pub ! Good Luck <3
There is a problem where when i call for refresh , allrows method brings me the same rows the i got.
here is the code.
List rows = await gSheet.sheet.values.allRows(fromRow: 2); print(rows.length);
try to insert new row to the google sheet and u will not get the new row or the list length right.