Why does visual studio not support file path characters allowed by Windows 10?

Jon Okie 1 Reputation point
2021-02-27T02:04:10.583+00:00

You can't use certain characters in paths of projects used within Visual Studio. These are characters supported by Windows 10. For example, your path cannot have a word in parentheses. I wish Microsoft would fix stuff like this. It makes me skeptical that Microsoft can lead the way into the future of development (ie .Net) when then can't seem to get simple things like this working (or fixed).

Visual Studio
Visual Studio
A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.
4,791 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. David Lowndes 4,711 Reputation points
    2021-02-27T11:04:07.187+00:00

    Please be specific about what you've found that doesn't work for you.

    For example, a quickly created C++ console project/solution named ConsoleApplication[{(2)}] can be created, but fails to build for me, resulting in:

    1>------ Rebuild All started: Project: ConsoleApplication[{(2)}], Configuration: Debug Win32 ------
    1>ConsoleApplication[{(2)}].cpp
    1>ConsoleApplication[{(2)}].vcxproj -> C:\Users\David\Source\Repos\ConsoleApplication[{(2)}]\Debug\ConsoleApplication[{(2)}].exe
    1>Set-Content : Could not find a part of the path 'C:\WINDOWS\SysWOW64\WindowsPowerShell\v1.0\Debug\vcpkg.applocal.log'.
    1>At D:\vcpkg\scripts\buildsystems\msbuild\applocal.ps1:12 char:5
    1>+ Set-Content -Path $copiedFilesLog -Value "" -Encoding UTF8
    1>+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    1> + CategoryInfo : ObjectNotFound: (C:\WINDOWS\SysW...kg.applocal.log:String) [Set-Content], DirectoryNotFoundException
    1> + FullyQualifiedErrorId : GetContentWriterDirectoryNotFoundError,Microsoft.PowerShell.Commands.SetContentCommand
    1>
    1>Split-Path : Cannot bind argument to parameter 'Path' because it is null.
    1>At D:\vcpkg\scripts\buildsystems\msbuild\applocal.ps1:40 char:39
    1>+ $baseTargetBinaryDir = Split-Path $baseBinaryPath -parent
    1>+ ~~~~~~~~~~~~~~~
    1> + CategoryInfo : InvalidData: (:) [Split-Path], ParameterBindingValidationException
    1> + FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCommand
    1>
    1>Split-Path : Cannot bind argument to parameter 'Path' because it is null.
    1>At D:\vcpkg\scripts\buildsystems\msbuild\applocal.ps1:58 char:35
    1>+ $targetBinaryDir = Split-Path $targetBinaryPath -parent
    1>+ ~~~~~~~~~~~~~~~~~
    1> + CategoryInfo : InvalidData: (:) [Split-Path], ParameterBindingValidationException
    1> + FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.SplitPathCommand
    1>
    ========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========

    Is that the same thing that you experienced?

    1 person found this answer helpful.