Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8338955
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T04:45:02+00:00 2026-06-09T04:45:02+00:00

I’m developing a Metro-style app (for Windows 8) using C# and XAML. I have

  • 0

I’m developing a Metro-style app (for Windows 8) using C# and XAML. I have set up my viewmodels to be used as design-time datacontexts, like so:

xmlns:vm="using:hub.ViewModels"
d:DataContext="{d:DesignInstance IsDesignTimeCreatable=True, Type=vm:ViewModels

My app appears to work perfectly when run, but in the design views of both VS 2012 and Blend, I occasionally get this (unhelpful) error message:

An Exception was thrown. TargetException: Error in the application.
Stacktrace
at System.ComponentModel.PropertyChangedEventHandler.Invoke(Object sender, PropertyChangedEventArgs e)
InnerException: None

This only happens in the design view – meaning I can’t set breakpoints around all my INotifyPropertyChanged() events.

What is the best approach to debugging design-time errors?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T04:45:04+00:00Added an answer on June 9, 2026 at 4:45 am

    If this happens consistently or semi-consistently, you can attach the debugger to the XAML designer:

    1. Start Visual Studio; open your project and open a XAML file, causing the XAML designer to load

    2. Start a second instance of Visual Studio. Open your project but make sure no XAML documents are open.

    3. Ensure that Just My Code is disabled: From the Tools menu, select Options. Select the Debugging category. In the General page, ensure the check box next to Enable Just My Code is unchecked.

    4. From the Debug menu, select Exceptions… and check the Thrown check box next to Common Language Runtime Exceptions. This will enable first chance handling of all CLR exceptions. If you know the specific type of the exception, you can enable first chance handling for just that type.

    5. From the Debug menu, select Attach to Process. In the Attach to: field, click Select… and check the Managed (v4.5, v4.0) entry in the list and click OK.

      This is necessary because the debugger may misdetect the process as a native process if it attaches while the process is executing native code. If your project contains native code, you’ll want to check the Native check box in the list as well (you can debug both managed and native code at the same time).

    6. In the Available Processes list box, find the xdesproc.exe that corresponds to your project and click Attach.

      If there are multiple processes (usually because you have multiple projects open or because the designer is reloading or has recently reloaded), it can be difficult to determine which designer process belongs to which Visual Studio instance. It’s often easiest just to attach to all of them. A tool like Process Explorer can help you figure out which designer process belongs to which instance of Visual Studio.

      Note: Do not attach the debugger to a designer process (xdesproc) that belongs to the same instance of Visual Studio that you are using for debugging: doing so is likely to cause Visual Studio to hang. You must always use two different instances of Visual Studio.

    7. Do whatever you need to do to repro the bug. When it occurs, the debugger will break at the point where the exception is thrown. The debugger should load the symbols for your assemblies.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
We're building an app, our first using Rails 3, and we're having to build
I have thousands of HTML files to process using Groovy/Java and I need to
I am using Paperclip to handle profile photo uploads in my app. They upload
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have just tried to save a simple *.rtf file with some websites and
I used javascript for loading a picture on my website depending on which small
I have a jquery bug and I've been looking for hours now, I can't

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.