Hello
I have a custom function on Google Sheets that can calculate distances.
Unfortunately, this function cannot be programmed within Excel
However,
The custom function contains 6 arguments:
=GOOGLEMAPS_DISTANCE(origin,destination,mode,waypoints1,waypoints2,waypoints3)
I need to create a function within my excel file that can:
- Connect to a Google Sheet file.
- Copy the same arguments to the Google Sheet file.
- Import the results.
So is this possible within Excel VBA?
And if possible how can I do that?
I have a custom function on Google Sheets that can calculate distances.
Unfortunately, this function cannot be programmed within Excel
However,
The custom function contains 6 arguments:
=GOOGLEMAPS_DISTANCE(origin,destination,mode,waypoints1,waypoints2,waypoints3)
I need to create a function within my excel file that can:
- Connect to a Google Sheet file.
- Copy the same arguments to the Google Sheet file.
- Import the results.
So is this possible within Excel VBA?
And if possible how can I do that?
Microsoft Excel Worksheet جديد.xlsx | |||||||||
---|---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | G | |||
1 | Arguments: | origin | destination | mode | waypoints1 | waypoints2 | waypoints3 | ||
2 | Inputs lable: | Al Janoub Stadium, 5H5F+XM4, Al Wukair, Qatar | Al Thumama Football Stadium, Al Thumama Bus Stop 7, Qatar | mode | Hyatt Regency Oryx Doha, Al Matar St, Doha, Qatar | Street 964، Doha, Qatar | Roundabout, Ar Rayyan, Qatar | ||
3 | Inputs value: | 25.16093563058944, 51.57521227538219 | 25.235618009695234, 51.53419445292399 | driving | 25.268043076335783, 51.554070158205334 | 25.19880223933868, 51.466069031137515 | 25.178574462243876, 51.39763378993048 | ||
4 | |||||||||
5 | |||||||||
6 | Function in excel: | #VALUE! | This function must copy the values of its arguments to google sheet to cells B3,C3,D3,E3,F3,G3 then imports results from cell C7 | ||||||
7 | |||||||||
8 | |||||||||
9 | Google sheet file name: | TEST_01 | |||||||
10 | Google sheet file LINK: | TEST-01 | |||||||
Sheet1 |
Cell Formulas | ||
---|---|---|
Range | Formula | |
B6 | B6 | =B3,C3,D3,E3,F3,G3 |