Visual Studio WPF Xaml Page PathGeometry String Max Length

vincent219 256 Reputation points
2022-07-27T10:11:34.883+00:00

225227-capture.png

Hello.

I am developing wpf in .NET Framework 4.8 using visual studio 2022 pro version.

I converted a 32 x 31 size png image into a svg file using an online converter site.

Then I converted svg to xaml code with this github program.

Then, the path information of the attached file was output.

Then, after copying and pasting the xaml of this file, visual studio does not recognize xaml as xaml from the next line, so IntelliSense does not work.

It behaves like a regular txt file.

Of course, it is well represented at runtime as a path image of the intent I want.

Does visual studio not recognize a string path longer than 36000 in length?

225254-path.txt225216-%E1%84%86%E1%85%A2%E1%84%85%E1%85%A7%E1%86%A8%E1%84%8B%E1%85%A1%E1%84%8B%E1%85%B5%E1%84%8F%E1%85%A9%E1%86%AB.png

Developer technologies Windows Presentation Foundation
Developer technologies Visual Studio Other
Developer technologies XAML
{count} votes

1 answer

Sort by: Most helpful
  1. Hui Liu-MSFT 48,676 Reputation points Microsoft External Staff
    2022-07-28T06:27:20.85+00:00

    Hi,@vincent219 . It might be an IntelliSense problem. You could split the Geometry of the longest data into two lines.
    Pressing enter before this position splits the data into two lines and IntelliSense works fine.
    225635-image.png
    Pressing enter on this position splits the data into two lines, IntelliSense does not work.
    225602-image.png
    The result:

    225577-image.png


    If the response is helpful, please click "Accept Answer" and upvote it.
     Note: Please follow the steps in our [documentation][5] to enable e-mail notifications if you want to receive the related email notification for this thread. 

    [5]: https://learn.microsoft.com/en-us/answers/articles/67444/email-notifications.html

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.