I have a project that was created in Blend + Sketchflow preview for Visual Studio 2012.
It is a simple project as I am learning C# and WPF for the first time. I have two windows. A simple start screen with a button that shows the other screen. The other screen has 4 buttons which change colors during a random order animation sequence.
My problem is that the design view became disabled. I can not open any XAML in design view anymore or edit any Storyboards etc. The only thing different I could think of is that I added a class file in Visual Studio 2012. After the project refreshed the design view went away and all I can see is the xml version of it.
If anyone can show me the solution I would appreciate it as I have searched google and stackoverflow and no answers have been found. I am new to both the language and VS/Blend so this may be a simple fix, I have no idea. Thanks in advance!
Make sure your project type is not set to 'console' as Blend will refuse to show design view for this type. If the project type is 'window', Blend will display design view just fine.
Also, Blend for VS2013 will not open a solution file if the target .NET Framework version is set to 4.5.2. A reset of the 'Target Framework' to 4.5.1 (or earlier) and Blend works fine.
I managed to solve this thanks to Surfbutler. My problem was I temporarily switched the project (output) type to console in Visual Studio 2012. When I switched it back to Window the design view started working properly again in Blend.
Related
Today I opened a project to find that none of its layouts will render in the designer.
I am pretty sure it is not an issue with my AXML as the app works fine when built. Visual Studio is up to date (15.9.9) and will display layouts in other projects without issue. My layouts are in the correct location (Resources/layout). I have tried -
Cleaning and rebuilding
Deleting the bin/obj folders manually and rebuilding the project
Turning Accelerated Rendering on/off in Options/Xamarin/Android UI Designer
Opening the project in Visual Studio for Mac (7.8) - same issue
Restarting Visual Studio/rebooting my computer
Any ideas on how to fix this would be greatly appreciated. I am not sure what part of the source would be useful to help with answering this question so please ask and I will provide.
Note - this project is on TFS.
This happened to mine and a colleague's Visual Studio a while ago, it was working then it was blank. We tried changing the target framework but couldn't get it working, I even completely reinstalled VS.
In our cases turning off "Enable Accelerated Rendering" in Tools > Options > Xamarin > Android UI Designer worked and we can now see the app as we build it. We didn't change the setting so assume it's the default, which makes me think it was caused by a VS update.
I have often run into this problem as well. Unfortunately, I have not found an easy fix to this problem other than restarting all instances of Visual Studio (and Android Studio if you have that running as well) followed by a full restart of my computer. Hopefully this help, good luck.
I found that the issue was caused by the target framework version of the app being set to Android 9.0. Setting this to 8.0 to match the version used by the designer fixed the issue.
I need the target framework to be version 9.0 and I can't figure out how to add versions to the designer (8.0 is the only one available to me). I have asked another question in regards to this (see here).
Using Visual Studio Professional 2017 (Release 15.2 26430.16), when I open a xaml file for a desktop UI that I have developed, I can no longer see the xaml designer (I only see the raw xaml code). This is new behaviour and may be due to me having a system clean-out, so maybe I removed an SDK that I need or something like that?
Are there any Visual Studio error logs I can check for warnings etc?
Frankly, your situation is different than mine. In my situation, it was because of Resharper. Maybe this may useful for someone else.
What to do is checking Resharper Options > Enviroment > Performance Guide > Disable XAML Designer.
It must be set to "Ignore" or "Show in Status Bar". Otherwise, it will always disable XAML Designer.
In the Visual Studio 2017 Installer, I selected all of the SDKs and installed the missing ones. This did not fix the problem by itself, but a subsequent 'repair' from the Visual Studio 2017 Installer (available from the 'hamburger' drop-down) did.
Sometimes, adding or removing SDKs from the Installer toggles the 'Enable XAML Designer' check box under Tools -> Options -> XAML Designer -> General (or perhaps it was the repair step that turned this back on), so ensure that this is checked.
Make sure XAML Designer is enabled.
Tools -> Options -> XAML Designer -> General -> Enable XAML Designer
I couldn't get the designer to work, but I found an alternate solution posted here, posted by #DamianSuess
Use the View > Other Windows > Xamarin.Forms Previewer menu in
Visual Studio to open the preview window. Use the Window > New
Vertical Tab Group menu to position it side-by-side.
forms-not-show-in-visual-studio
I know this issue is tagged as WPF but I had a similar issue for Xamarin Forms.
What solved this issue for me:
Right Click the xaml file
Select "Open With..."
Select Xamarin.Forms Previewer
Click OK
Optionally, you can set the Xamarin.Forms Previewer as the default for xaml files
make sure you have correctly installed the Windows 10 SDK, there are 3-4 versions of the SDK, the error you are talking about can also be a consequence of a incompatible sdk,
also reinstall the sdk related to your app, close every process related to Visual studio running in background while reinstalling the SDK.
Can you share a screenshot of the xaml designer page?
I had the same, I found that opening the XAML in VS community did not work. However, if I choose file -> open -> project/solution and open the corresponding sln file, it works.
When I create UWP or windows phone project and try to edit a page in xaml, no visual changes displayed in the editor - it just stays empty. However, borders of selected element are displayed. So it can be defined that editor processes layout right, but displays no visual part of elements.
The problem occurs on visual studio 2015 proffesional, and also vs 2017 community. So I think problem is not related to IDE, maybe something wrong with SDK.
Hyper-V is enabled if it makes any difference.
Tashiu,
Set the
project properties
->Application
->Target version to Windows 10(10.0;Build 10240),
the design view shows up again.
It always says "The solution "foo.sln" is of an unsupported Format and may not open correctly. Do you want to open the solution anyway?" If I click yes, it Shows the solution tree, but when I open a xaml file, it only Displays its xaml text, not the Rendering of the UI.
According to this http://blendinsider.com/technical/available-now-blend-for-visual-studio-2012-2012-08-15/ Blend 4 is the way it's meant to work. So something is wrong I guess.
I have older Projects created with vs2010 and Blend 4. I can still open and work in them in Blend 4 while working on them in vs2012. Only new Projects created with vs2012 seem to have this Problem for me.
When you open a VS2012 project in blend 4, a message like this is showed:
The thing is that if you click the yes button then it will open the project, but if the target framework of the project is 4.5 then the blend only will show you the Xaml code, and no more else. But if the target framework of your project is 4.0 or lower, then you will may edit the project as normally you have done before.
Hope this could helps you...
I'm busy with a Windows Phone 7 application using Visual Studio 2010 only. I've read that one can also use Expression Blend to develop the app. But there a few things that I'd like to clear up regarding how one works with both these applications when developing an app.
Firstly I know how it works in Visual Studio, you can create the UI with xaml code, and then add interactivity with your C# code. So what exactly is Expression blend for? Is it more geared toward designing the interface and not so much interactivity? Can you do interactivity in Expression blend at all?
From what I can gather (again I'm not sure about this), one works with both these applications. Expression Blend for the UI, and Visual Studio for the back-end/interactivity. Is this correct?
Assuming that the above is correct. How do you go about this? Can you work on the same solution in both programs? What would your typical workflow be like when working on both these programs?
Thanks in advance!
Your assumptions are correct; Visual Studio is used primarily to write the code that makes the programs work, while Blend is used to design the UI. Blend primarily works by dragging UI elements into their desired position, though you can also directly manipulate the XAML if you wish, or both, even.
You can edit the code-behind in Blend, but you'll be missing a lot of functionality Visual Studio offers in that department.
You can have the same solution open in both Blend and Visual Studio and switch between them as needed, but changes to either won't be picked up by the other until you save the modified files.
Personally, I use Visual Studio for the coding, and Blend for the design. Both open at the same time, with the same solution loaded.