MaterialDesignInXAML / MaterialDesignInXamlToolkit

Google's Material Design in XAML & WPF, for C# & VB.Net.
http://materialdesigninxaml.net
MIT License
15.12k stars 3.42k forks source link

Something went wrong with Demo projects in VS 2017 WPF solution #804

Closed tsilvs closed 5 years ago

tsilvs commented 7 years ago

So, I've downloaded .zip from master branch, unpacked it, opened "MaterialDesignToolkit.WPF" solution in my Visual Studio 2017 (v 15.3.5) and got 25 errors like "The name does not exist in the namespace"

Is something wrong with VS or it could be fixed by downloading something? materialdesignxamltoolkit_demo_errors

ButchersBoy commented 7 years ago

What's the very first error?

tsilvs commented 7 years ago

The name "TabablzControl" does not exist in the namespace "clr-namespace:Dragablz;assembly=Dragablz". In App.xaml

And 59 warnings (yellow triangles) mostly about "The referenced component could not be found"

BTW TY for reacting so soon. I'm new to GitHub, VS and all this stuff.

Keboo commented 7 years ago

@JeffRockatansky i would suspect that dependencies are missing. After attempting to build the solution (packet and the dependencies should download as part of the build process), check and see if there packages directory in the same folder as the solution.

If it is missing try turning up your build output to at least Detailed and examine the output. I suspect some other error is actually what is causing the issue.

tsilvs commented 7 years ago

@Keboo Packages folder is empty huh. But it's present in the same folder as solution :D Output has a big scary wall of text. Didn't find anything useful yet.

Keboo commented 7 years ago

If you expand the references in MapAppsDragablzDemo (the project showing the errors in your screenshot) does it show that all of the references have resolved?

Should look like this (no little yellow triangles on any of the references).

image

tsilvs commented 7 years ago

materialdesignxamltoolkit_demo_references How to fix "yellow triangles" of Dragablz and MahApps.Metro? (Is it actually Dragon Ball Z reference?)

BTW "MaterialDesignDemo" (aka Main Demo) works fine. Somehow. No errors. But Dragablz doesn't. Is it ok? Do I even need it?

Keboo commented 7 years ago

If you are not wanting to use the MahApps/Dragablz stuff, no you don't need and can simply unload it.

tsilvs commented 7 years ago

Ok TY and sorry :D

tsilvs commented 7 years ago

So, if I need Dragablz features to look at in demo, I need to clone Dragablz, compile it and add it's .dll in References of this Material wpf demo?

tsilvs commented 7 years ago

And what if I need them both in my own project, but not the Metro one?

tsilvs commented 7 years ago

Tried to add (not all at the same time) 3 different .DLL's for each of Dragablz and MahApps.Metro for Material + Dragablz Demo. Ones from "Package" folder, others - from masters of sources compiled on my PC. Tried 40 and 45 versions. "Build successful" every time, but it crashes with error or in debug enters Break point state.

ButchersBoy commented 7 years ago

You should never need to recompile anything.

Ideally you should start new projects and add any combination of Material Design, Dragablz, MahApps, via nuget.

As for the demo. I have just retested. Downloaded a clean .zip (normally I do a "git clone" from cmd line). Opened in VS2017, compiled, ran. All references were OK, project ran fine. You will see some errors in the designer. That is VS. But ignore these for now; the project should run.

Aycom366 commented 4 years ago

i downloaded the material design themes just now for my vs 2017 and on loading the project, i got these errors

Severity Code Description Project File Line Suppression State Error The current .NET SDK does not support targeting .NET Core 3.1. Either target .NET Core 1.1 or lower, or use a version of the .NET SDK that supports .NET Core 3.1. MaterialDesignColors.Wpf.Tests C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\Sdks\Microsoft.NET.Sdk\build\Microsoft.NET.TargetFrameworkInference.targets 112

Severity Code Description Project File Line Suppression State Error MSB3073 The command ""C:\kenny folder\Setups\MaterialDesignInXamlToolkit-master\MaterialDesignInXamlToolkit-master.paket\paket.exe" restore" exited with code 1. MaterialDesignThemes.Wpf.Tests C:\kenny folder\Setups\MaterialDesignInXamlToolkit-master\MaterialDesignInXamlToolkit-master.paket\Paket.Restore.targets 171

and also, some material design themes choose not to load...always writting load failed

Am using VS 2017, .net core 2.1

Keboo commented 4 years ago

@Aycom366 see https://github.com/MaterialDesignInXAML/MaterialDesignInXamlToolkit/wiki/Compiling-From-Source You will need VS2019 and .NET Core 3.1 to compile from source.

mey1k commented 4 years ago

I can't run MahAppsDragablzDemo it occurs System.Windows.Baml2006.TypeConverterMarkupExtension Exception