Skip to main content
StefanStehlik
Inspiring
Dec 1, 2022 8:10 AM UTC
Answered

VS Code - $.writeln

Is there a way to print out variable values into the VS Code's variable section or print it to the console? The variable section is always empty and the watch section is always returning 'not available' massage for variables when running a script.

This topic is closed to new replies. Start a new post to keep the conversation going.
StefanStehlik
StefanStehlikCorrect answer
Inspiring
Jan 28, 2023 8:52 PM UTC

Justin thank you for your response. I found the solution by using attach mode when running scripts in VS Code

17 replies

Legend
Oct 30, 2024 6:03 PM UTC

Try this:

 

 

Translate
Inspiring
Oct 30, 2024 6:28 PM UTC

In my case it doesn't work.

upd.
After reinstalling VS Code works.
Thank you, useful information

Translate
Legend
Oct 30, 2024 6:42 PM UTC

I don't think so. 🤔 🤔

 

Look at your screenshot

 

You probably simply evaluate the script 

 

My window:

 

 

 

Translate
Justin Taylor-Hyper Brew
Community Expert
Community Expert
Jan 27, 2023 6:48 PM UTC

Are you on the latest version of the VS Code ExtendScript extension? Variables will only be updated when hitting a breakpoint, but $.writeln() should show up in the terminal.

Translate
StefanStehlik
StefanStehlikAuthorCorrect answer
Inspiring
Jan 28, 2023 8:52 PM UTC

Justin thank you for your response. I found the solution by using attach mode when running scripts in VS Code

Translate
Justin Taylor-Hyper Brew
Community Expert
Community Expert
Jan 29, 2023 7:40 PM UTC

Great to hear it's working!

Translate