question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

F8 selection on code

See original GitHub issue

System Details

  • Operating system name and version: Windows 10 Latest version
  • VS Code version: 1.12.2
  • PowerShell extension version: 1.0
  • Output from $PSVersionTable: PSVersion 5.1.15063.296 PSEdition Desktop PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…} BuildVersion 10.0.15063.296 CLRVersion 4.0.30319.42000 WSManStackVersion 3.0 PSRemotingProtocolVersion 2.3 SerializationVersion 1.1.0.1
Copy / paste the below commands into the PowerShell Integrated Terminal, and paste the output here

code -v
1.12.2
19222cdc84ce72202478ba1cec5cb557b71163de

$pseditor.EditorServicesVersion
Major  Minor  Build  Revision
-----  -----  -----  --------
1      0      0      0
code --list-extensions --show-versions
AdamCaviness.theme-monokai-dark-soda@0.0.5
akamud.vscode-theme-onelight@1.3.2
anoff.theme-monokai-light@1.0.3
DougFinke.vscode-PSStackoverflow@0.0.2
dustinsanders.an-old-hope-theme-vscode@2.0.0
formulahendry.code-runner@0.6.16
gerane.Theme-monokai-best@0.0.2
jmrog.vscode-nuget-package-manager@1.1.3
karyfoundation.theme-karyfoundation-themes@12.0.0
Kipters.codeshell@0.2.2
ms-vscode.csharp@1.9.0
ms-vscode.PowerShell@1.0.0
remcoros.startanyshell@0.3.1
robertohuertasm.vscode-icons@7.7.0

$PSVersionTable
As Above

Issue Description

When highlighting more than one line of PowerShell code in VS Code and pressing F8, the integrated console try to run each line separately. So i have to save the code in a file and run the file from the prompt.

Attached Logs

Follow the instructions in the README about capturing and sending logs.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:11 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
daviwilcommented, May 17, 2017

Hey Graham, check your keybindings and see if you have F8 bound to workbench.action.terminal.runSelectedText. If so, remove that binding so that the PowerShell extension’s PowerShell.RunSelection binding gets used.

0reactions
daviwilcommented, May 17, 2017

No problem Graham!

Read more comments on GitHub >

github_iconTop Results From Across the Web

how to enable the f8 on selection-screen - SAP Community
F8 is atomatically enabled for executable programs . AT SELECTION-SCREEN event is used to validate the selection screen variables and display the result...
Read more >
VS Code, F8 shows command history - Stack Overflow
This becomes a problem when I press F8 in the editor pane to run a selection of PowerShell code, the code runs, but...
Read more >
Candidate for most obscure keyboard shortcut: Shift+F8
Type Shift+F8 once to enter extended selection mode, then use the arrow keys to select an item and press Ctrl+Space or Shift+Space to...
Read more >
Selecting Cells in Excel using the F8 key
So, SHIFT + F8 allows us to select non-adjacent cells. As in our previous example, make sure you see the text in the...
Read more >
Keyboard shortcuts for Windows - Visual Studio Code
Copy line (empty selection). Alt+ ↑ / ↓ ... Shift+F8. Go to previous error or warning. Ctrl+Shift+Tab ... Move last selection to next...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found