Windows 10: Annoying error in PowerShell

  1.    11 Sep 2017 #1

    Annoying error in PowerShell


    I have a directory E:\Documents\Steve's\New Documents\Tax
    If I navigate to this directory in explorer, and then use the File->Open Windows Powershell mechanism, then Windows PowerShell opens with the error:

    The string is missing the terminator: '. + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : TerminatorExpectedAtEndOfString

    There's nothing wrong with a single quote character in a directory, so this must be an error in Powershell.

    Is that correct?
      My ComputerSystem Spec

  2.    11 Sep 2017 #2

    Swifty said: View Post
    I have a directory E:\Documents\Steve's\New Documents\Tax
    If I navigate to this directory in explorer, and then use the File->Open Windows Powershell mechanism, then Windows PowerShell opens with the error:

    The string is missing the terminator: '. + CategoryInfo : ParserError: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : TerminatorExpectedAtEndOfString

    There's nothing wrong with a single quote character in a directory, so this must be an error in Powershell.

    Is that correct?
    You need double quotes around filename "E:\Documents\Steve's\New Documents\Tax".


    Click image for larger version. 

Name:	image.png 
Views:	21 
Size:	3.5 KB 
ID:	152768
      My ComputerSystem Spec


  3. Posts : 8,143
    10 Home x64 (1803) (10 Pro on 2nd pc)
       11 Sep 2017 #3

    cereberus said: View Post
    You need double quotes around filename "E:\Documents\Steve's\New Documents\Tax".
    Any idea how to do that when opening Powershell from File Explorer's 'File' tab as the OP is trying to do? Or with the Shift+RightClick context menu?
      My ComputersSystem Spec

  4.    11 Sep 2017 #4

    cereberus said: View Post
    You need double quotes around filename "E:\Documents\Steve's\New Documents\Tax".

    I'm not the one issuing the CD command. I'm using the option inside the "File" entry in Windows Explorer, all done with a couple of mouse clicks...
    Perhaps it's Windows Explorer which needs to punctuate the command it uses to open Pwershell at my directory.

    Try it for yourself:

    1. Open Windows Explorer
    2. Navigate to a directory of your choice
    3. Create a new directory, maybe "cereberus's"
    4. Navigate to this new directory
    5. Click the "File" entry in Explorer's ribbon
    6. Click "Open Windows Powershell"
    7. Marvel at the error message...

      My ComputerSystem Spec

  5.    11 Sep 2017 #5

    Swifty said: View Post
    I'm not the one issuing the CD command. I'm using the option inside the "File" entry in Windows Explorer, all done with a couple of mouse clicks...
    Perhaps it's Windows Explorer which needs to punctuate the command it uses to open Pwershell at my directory.

    Try it for yourself:

    1. Open Windows Explorer
    2. Navigate to a directory of your choice
    3. Create a new directory, maybe "cereberus's"
    4. Navigate to this new directory
    5. Click the "File" entry in Explorer's ribbon
    6. Click "Open Windows Powershell"
    7. Marvel at the error message...

    [/COLOR]
    Yeah obviously a silly bug.

    I guess quickest way to avoid typing long names is to

    1) navigate to folder

    2) click on directory icon in name bar

    Click image for larger version. 

Name:	image.png 
Views:	17 
Size:	3.9 KB 
ID:	152779

    which yields

    Click image for larger version. 

Name:	image.png 
Views:	17 
Size:	1.7 KB 
ID:	152780
    3) Press ctrl-c to pu on clipboard.

    Then open powershell and type CD " , paste clipboard and type final ".
    Attached Thumbnails Attached Thumbnails image.png  
      My ComputerSystem Spec


 

Related Threads
That annoying 0x800704cf error... in Network and Sharing
This is something I see with every fresh installation of Windows 8 and later. I have a file server, called FILES, which is a Windows 8.1 Pro machine with a bunch of shared folders. I use several Windows 10 Pro machines to connect to these shares...
Hello everyone. This is my first time here so I'm hoping I'm in the right section and that the title is clear and all that. So basically I had some trouble with viruses a while back. I did manage to get rid of them (I think) but my PC has been a bit...
I am trying to cleat all the events in my event viewer as I had so many errors in the past 7 days. I opened powershell & ran as administrator & use this command wevtutil el | Foreach-Object {wevtutil cl $_} & I had some access denied errors....
hi . i ve recently installed a windows 10 and every time i try to run a game this error happens 0xc000007b and i ve directx 12 & netframe 4.5 or 4.6 idk " latest version " & and the VCredist and i ve done every thing to do with the "DLL"s move them...
Can someone tell what the powershell errors means? when i put this commend ((Get-ChildItem "HKLM:SOFTWARE\Microsoft\Windows\CurrentVersion\Appx\AppxAllUserStore\InboxApplications") | Get-ItemProperty).Path | Add-AppxPackage -Register...
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 08:48.
Find Us