Answer the question
In order to leave comments, you need to log in
How to calculate coordinates for google spreadsheets?
Good afternoon. Need help calculating coordinates in Google spreadsheets.
What is:
$spreadsheetId = "индификатор_документа";
$range = "Книга1!A1:ZZ1";
$response = $service->spreadsheets_values->get($spreadsheetId, $range);
$values = $response->getValues();
array:1 [
0 => array:97 [
0 => ""
1 => "Ссылка на отчет"
2 => "Итого июнь"
3 => "01.06.2016"
4 => "02.06.2016"
5 => "03.06.2016"
6 => "04.06.2016"
7 => "05.06.2016"
8 => "06.06.2016"
9 => "07.06.2016"
10 => "08.06.2016"
11 => "09.06.2016"
12 => "10.06.2016"
$service->spreadsheets_values->update
function getNameFromNumber($num)
{
$numeric = $num % 26;
$letter = chr(65 + $numeric);
$num2 = intval($num / 26);
if ($num2 > 0) {
return getNameFromNumber($num2 - 1) . $letter;
} else {
return $letter;
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question