scripts's People
Forkers
misi3k124 lundeen-bryan pterameta wfcheong ottoellison98 markbirss gulopez leo-reyna mercolani quito96 admariner lucasozim alk47 canadianphilosopher ashwanijha4 truestone srivallivijay salmanulfaries samishafe rickkotlarz mohammedmahmood linlinak76 lincolnassy duncanomondi cpsethi25 amanda-judy mol01 raciel88p shohiduzjaman7 cryptobuks george-strother axox1990 armedwar dbzdivik alphadera-labs lingling82 zilles111 ruhul8357 thajj ahmadmuhammadxo rildo-f-ribeiro opzet davidoster cityjayjay zsl1034 rlagosdev adams216 importante webllrzjohnson blesst88 andigalpern rodrigonz iamsathish samokoye ashrafbotrous chas-mellish hoanghienvi maayansv gamoman drewbied0 marieleyse driondavies georgesantaki bonbon622 maksour92x bemot han-tun shawnhank samahmaalouf ali2kan mdekens harbakshsingh ducthpoc zwoaxy chaibezsahara tychomagneticanomaly-1 pables-bsu winterhouse052061 s-austin2012 dincerdogan flashbat51 virtualadrian enowithdh hmcheong bahattab vpm007 deebee699 rasheed-devt robles365 typemiguel ylakovsky massoudsaidi tonywhite11 nasirarslan35 ariconnect robert0777scripts's Issues
Line 46 error
Hello,
I have this error when I use the script : "Line 46: Cannot read properties of undefined (reading โ0โ)"
Why ? any help please ?
I correctly set the key in excel. I have automate tab. I am working with office 365 online.
Thanks for help.
undefined is not an object (evaluating 'json.choices[0]')
I have downloaded the XelPlus ASK AI in EXCEL.xlsx file, and copied the ts script into the Code Editor. I have replaced the Initial "button" with a new button linked to the Open AI in Excel script. I have established an API, and have copied it to cell B1 on the "API" tab. I have entered "Who won the 1985 World Series?" into cell B2 on the "Prompt" tab. When I run the code, I get the error "undefined is not an object (evaluating 'json.choices[0]'). I have added a console.log statement to write out json() following the "await response.json()" statement. The output appears to be blank.
OpenAI in Excel script is running, but not returning the correct answer
Great video! I got the script to run without error. However, it doesn't answer the question I write into cell B2 on the 'Prompt' sheet. The first time I run it, it returns an answer of sorts, but it isn't an answer to the question I've asked. Subsequent running of the scripts returns random lines of code. I must have missed a step somewhere, but I can't figure it out. Any help?
hi
No output result
I've tried to follow the instruction on the video but I found the following issue ๐
- if tI use the ts code as is, I get an error ("type error"). I was able to fix the problem enclosing the provided sript inside this code
function main(workbook: ExcelScript.Workbook) {
// Your code here
}
- after fixing above problem, I can input a question but I have no answer. Nor errors or warning in the output console.
API works, if I use a curl request with similar settings for model and prompt, I get my answer but in xls nothing happen.
I also added some extra logging lines but still no error in Output or Problems view.
Thanks for support.
Bring ChatGPT inside Excel issue
Dear Leila,
I copy pasted your office script into code editor and this is the error message I got:
Line 46: Cannot read properties of undefined (reading '0') Can you help me?
This is the solution proposal from chat gpt but it didn't really help me:
"The error message "Cannot read properties of undefined (reading '0')" on line 45 typically means that you are trying to access an index of an array or an object property that does not exist. The error message suggests that the object or array you are trying to access is undefined.
To solve this issue, you need to make sure that the object or array you are accessing is defined and contains the property or index you are trying to access. Here are some steps you can take to solve the error:
Check if the object or array you are trying to access is defined. If it is undefined, make sure it is initialized properly.
Check if the property or index you are trying to access exists. If it does not exist, you may need to create it or modify your code to access a different property or index.
Check if the object or array you are trying to access is being modified or deleted before the error occurs. If it is, you may need to modify your code to prevent these actions or ensure they happen in the correct order.
Use console.log statements to log out the values of the variables involved in the error. This can help you pinpoint where the error is occurring and what values are causing the issue.
By following these steps, you should be able to solve the "Cannot read properties of undefined (reading '0')" error on line 45."
excel
hi
"Script is running" but nothing happens
Windows 10, office 365. I pasted in the .ts and put in the apiKey. I can run it, no compile errors, but it never terminates.
Pity there is no way to single step I Officescript code.
I put in a console.log but nothing happened.
Error - Excel cannot openthe file... file format/file extension is not valid.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.