A Google Script that via scraping the Avanza network traffic returns a stocks lastprice or a funds latest known NAV, reachable by custom functions in Google Spreadsheet
Theese instructions will help you set up the script, and use it in for example Google Spreadsheet
None really, all is done in the browser
-
Open up the Spreadsheet you want to use the functions in
-
Head to Tools -> Script Editor
-
Copy and paste the code in code.gs (or download code.gj and go "file -> open -> locate code.gs on your computer")
-
Go to Triggers (the clock) -> add trigger
-
Choose lastPrice as function to run, and On Open as event type -> Save
-
Add trigger -> choose nav as function to run an on Open as event type -> Save
-
Use the functions as follows:
=lastPrice(id)
Where id is the ID that Avanza provides in the URL.
=nav(id)
Where id is the ID that Avanza provides in the URL