none
Application window is transparent.

    Question

  • I am trying to run/debug a WPF application, but as soon as I launch it, the main application window pops-up, and the body of the window is transparent.  I see the title bar, and the application shows in the task bar, but the window body is transparent.  I am remoting into a machine (via Windows Remote Desktop) that has a VM running.  This VM is where I'm trying to run/debug the application.  All 3 machines are running Windows 7.  Is it because of my environment that I can't see the body of the window?  I can run/debug WinForms apps just fine - but WPF windows all show up transparent.

    Friday, December 16, 2011 5:25 PM

Answers

  • All - the link above didn't directly help me (the registry key mentioned didn't exist in my registry), but it did lead me to this solution:

     In the application class' OnStartup method, add this line (conditionally):

    RenderOptions.ProcessRenderMode = System.Windows.Interop.RenderMode.SoftwareOnly;

     

    Thanks all for your help!!!

     

    Friday, January 13, 2012 3:06 PM

All replies

  • WPF windows typically do work via remote desktop (though they're slower than local copies, in many cases).  Is it all WPF windows, or a specific one?

     


    Reed Copsey, Jr. - http://reedcopsey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Mark as Helpful".
    Friday, December 16, 2011 5:53 PM
  • I have a couple WPF applications, and all of them show transparent.  
    Friday, December 16, 2011 5:59 PM
  • I would check the VM settings - it's possible it's having problems with WPF's hardware acceleration requirements.  WPF tries to hardware accelerate the graphics, which shouldn't happen on a VM, but it may be attempting it.  You can change the settings of the system, which may correct the problem.

     

    For details, see the Graphics Settings section for WPF on MSDN: http://msdn.microsoft.com/en-us/library/aa970912.aspx


    Reed Copsey, Jr. - http://reedcopsey.com
    If a post answers your question, please click "Mark As Answer" on that post and "Mark as Helpful".
    Friday, December 16, 2011 6:14 PM
  • Hi mmckain,

    Any update on this issue? Does the problem presists in software rendering mode?


    Min Zhu [MSFT]
    MSDN Community Support | Feedback to us
    Monday, December 19, 2011 7:43 AM
  • Try to change your OS Graphic setting in the VM, refer to: http://msdn.microsoft.com/en-us/library/aa970912.aspx as Reed pointed. And then test your WPF windows again. On the other hand, could you please tell us what kind of your VM and the virtual/physical hardware information?

    Sincerely,


    Bob Bao [MSFT]
    MSDN Community Support | Feedback to us
    Wednesday, December 21, 2011 8:55 AM
  • All - the link above didn't directly help me (the registry key mentioned didn't exist in my registry), but it did lead me to this solution:

     In the application class' OnStartup method, add this line (conditionally):

    RenderOptions.ProcessRenderMode = System.Windows.Interop.RenderMode.SoftwareOnly;

     

    Thanks all for your help!!!

     

    Friday, January 13, 2012 3:06 PM