1

I have used Visual Studio Community 2015 and there was no problem. Since I updated to 2017...well...there is some issues...

When I drop new object to grid in WPF...no default name...both in the property window and the XAML code...mostly I design applications using XAML code, I do not use the property window. It is very frustrating to type for each new object x:Name = "Button", "TextBox" etc...

And to make things worse...Visual Studio works like how he wants...one day this is the default, second day I have to manually write. In 2015 this was always the default. Has anyone had a similar experience, whether you need to adjust something or is this really a bug?

panzer
  • 133
  • 9
  • 2
    Whether this is a bug or not is a matter of opinion. Since you can write whole WPF programs without naming a single element, I'm surprised to hear that the Designer would by default assign names to things (I type XAML in directly, so I'm unfamiliar with the habits of Blend/WPF Designer). But I certainly think it makes more sense to _not_ give everything a name. Seems to me, if you would write your WPF programs correctly, using MVVM, data-binding, etc. such that your elements don't need names, you would no longer be frustrated that the Designer doesn't give your elements names by default. – Peter Duniho Jun 03 '17 at 07:34

1 Answers1

3

Go to: Tools->Options->XAML Designer Select: 'Automatically name interactive elements on creation'

Now VS designer will name your new objects.

Maciek Świszczowski
  • 1,155
  • 11
  • 28