Install ClickOnce a published DPI-enabled application

I have a problem that drives me crazy.

I am using a professional visual studio 2010. I am creating an application that supports dpi in such a way that Microsoft has shown here , which usually adds a manifest to the application containing this:

<?xml version="1.0" encoding="utf-8"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" >
  <asmv3:application>
    <asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
      <dpiAware>true</dpiAware>
    </asmv3:windowsSettings>
  </asmv3:application>
</assembly>

Then I publish my application and I try to install it. Complete failure. During installation, a window appears with an error that the application is not formatted properly (this is a translation, I am using the Polish version of the operating system). The error log shows that during the creation of the manifest there was an exception HRESULT 0x8007001f. This exception means "device is not working." Fine, but which device ?.

A Google study showed that such an error that I encountered could have something to do with improperly signing the assembly. I spent several hours trying to solve this binding in order to sign the assembly in various ways without success.

What I found is that it is enough to comment on the tag <windowsSettings>for comments, and then the application installs well, even without subscribing to the assembly at all. I wonder if this is due to the fact that when you enter this URL in the xmlns attribute of this tag in a web browser, the server responds with "Error processing your request." message.

- ? win7, win7 64 winxp , ... , Google . , ClickOnce dpi?

+5
1

DPI . - :

[System.Runtime.InteropServices.DllImport("user32.dll")]
private static extern bool SetProcessDPIAware();

[STAThread]
static void Main()
{    
    if (Environment.OSVersion.Version.Major >= 6) SetProcessDPIAware();

    Application.EnableVisualStyles();
    Application.SetCompatibleTextRenderingDefault(false);
    ...

app.manifest, .

+2

All Articles