Is there any way to AutoFit Column width in Google Sheets using Google Sheets API? I can find only DimensionProperties but it needs exact value n pixels.
You can achieve it using autoResizeDimensions of Sheets API. You can see the detail information at below links.
POST https://sheets.googleapis.com/v4/spreadsheets/### fileId ###:batchUpdate
{
"requests": [
{
"autoResizeDimensions": {
"dimensions": {
"sheetId": sheetId,
"dimension": "COLUMNS",
"startIndex": 0,
"endIndex": 3
}
}
}
]
}
If I misunderstand your question, I'm sorry.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With