Xp主题 [英] Xp Themes

查看:54
本文介绍了Xp主题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的应用程序使用


Windows.Forms.Application.EnableVisualStyles()

Windows.Forms.Application.DoEvents()


我收到了一些错误,所以我想去一个清单文件,但是我将b $ b复制一个新闻组 - 见下文


<?xml version =" 1.0"编码= QUOT; UTF-8英寸standalone =" yes"?>

< assembly xmlns =" urn:schemas-microsoft-c?* om:asm.v1" manifestVersion =" 1.0">

< assemblyIdentity

version =" 1.0.0.0"

processorArchitecture =" X86" ;

name =" MyApp"

type =" win32"

/>

<依赖>

< dependentAssembly>

< assemblyIdentity

type =" win32"

name =" ; Microsoft.Windows.Common?* - 控制"

version =" 6.0.0.0"

processorArchitecture =" X86"

publicKeyToken =" 6595b64144ccf1?* df"

language =" *"

/>

< / dependentAssembly>

< / dependency>

< / assembly>


当您将此文件作为文件时,请在VS中执行以下操作。 NET IDE:

1.选择文件>打开文件

2.打开您的可执行文件

3.右键单击父节点并选择' '添加资源''

4. C hoose导入并选择清单文件

5.当出现询问资源类型类型的框时RT_MANIFEST

6.资源标识符必须为1,因此选择'

RT_MANIFEST文件夹中的'101''并将其更改为1

我按照这些步骤操作,当我尝试在调试中运行我的应用程序或
$ b从我得到的exe中得到$ b。


此应用程序无法启动,因为应用程序配置

不正确。重新安装应用程序可以解决这个问题。


任何帮助将不胜感激。

I had my app using the

Windows.Forms.Application.EnableVisualStyles()
Windows.Forms.Application.DoEvents()

And I was receiving some errors, so I want to go to a manifest file, but I
copied one off a newsgroup -- see below

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-c?*om:asm.v1" manifestVersion="1.0">
<assemblyIdentity
version="1.0.0.0"
processorArchitecture="X86"
name="MyApp"
type="win32"
/>
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common?*-Controls"
version="6.0.0.0"
processorArchitecture="X86"
publicKeyToken="6595b64144ccf1?*df"
language="*"
/>
</dependentAssembly>
</dependency>
</assembly>

When you have this as a file do the following in the VS .NET IDE:
1. Select File>Open File
2. Open your executable file
3. Right click the parent node and select ''Add Resource''
4. Choose Import and select the manifest file
5. When the box appears asking for the type of resource type RT_MANIFEST
6. The resource identifier needs to be 1, so select ''101'' in the
RT_MANIFEST folder and change it to 1
I followed these steps and when I try to run my application in debug or
right from the exe I get.

"This application has failed to start because the application configuration
is incorrect. Reinstalling the application may fix this problem.

Any help would be appreciated.

推荐答案

只需命名你的清单文件与您的exe文件同名,除了添加

a .manifest扩展名。因此,如果您的exe是名称Form1.exe,您的

清单文件应该命名为Form1.exe.manfiest,并且应该位于

与exe文件相同的目录中。当你把它作为一个资源添加到执行代码时,你将它嵌入到我之前做过的exe中,并且

没有任何问题。

Just name your manifest file the same name as your exe file except add
a .manifest extension to it. So if your exe is name Form1.exe, your
manifest file should be named Form1.exe.manfiest and should reside in
the same directory as the exe file. When you add it as a resource to
the exe, you are embedding it in the exe, which I have done before and
haven''t had any problems.


只需将您的清单文件命名为与exe文件相同的名称,除了添加

a .manifest扩展名。因此,如果您的exe是名称Form1.exe,您的

清单文件应该命名为Form1.exe.manfiest,并且应该位于

与exe文件相同的目录中。当你把它作为一个资源添加到执行代码时,你将它嵌入到我之前做过的exe中,并且

没有任何问题。

Just name your manifest file the same name as your exe file except add
a .manifest extension to it. So if your exe is name Form1.exe, your
manifest file should be named Form1.exe.manfiest and should reside in
the same directory as the exe file. When you add it as a resource to
the exe, you are embedding it in the exe, which I have done before and
haven''t had any problems.


如果你读了我的解释,我做了所有这些,我想出了一个错误。

所以我需要一些帮助我放入清单文件中的内容以及我用

跟随嵌入清单文件的指令。


" Jamin Guy"写道:
If you read my explaination I did all that and I''m coming up with an error.
So I need some help with what I put in my manifest file and the directions I
followed to embed the manifest file with the exe.

"Jamin Guy" wrote:
只需将您的清单文件命名为与您的exe文件相同的名称,除了添加
一个.manifest扩展名。因此,如果您的exe是名称Form1.exe,您的
清单文件应该命名为Form1.exe.manfiest,并且应该位于与exe文件相同的目录中。当你把它作为一个资源添加到exe中时,你将它嵌入到exe中,我之前已经做过了,并且没有任何问题。
Just name your manifest file the same name as your exe file except add
a .manifest extension to it. So if your exe is name Form1.exe, your
manifest file should be named Form1.exe.manfiest and should reside in
the same directory as the exe file. When you add it as a resource to
the exe, you are embedding it in the exe, which I have done before and
haven''t had any problems.



这篇关于Xp主题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆