惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

酷 壳 – CoolShell
酷 壳 – CoolShell
H
Hacker News: Front Page
P
Palo Alto Networks Blog
T
ThreatConnect
Apple Machine Learning Research
Apple Machine Learning Research
博客园_首页
T
True Tiger Recordings
P
Privacy & Cybersecurity Law Blog
B
Blog
IT之家
IT之家
Last Week in AI
Last Week in AI
F
Full Disclosure
Hacker News: Ask HN
Hacker News: Ask HN
C
Comments on: Blog
Microsoft Azure Blog
Microsoft Azure Blog
C
Cybersecurity and Infrastructure Security Agency CISA
Microsoft Security Blog
Microsoft Security Blog
博客园 - 【当耐特】
N
News and Events Feed by Topic
NISL@THU
NISL@THU
腾讯CDC
雷峰网
雷峰网
Security Latest
Security Latest
李成银的技术随笔
M
Microsoft Research Blog - Microsoft Research
L
LangChain Blog
L
Lohrmann on Cybersecurity
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
Check Point Blog
Y
Y Combinator Blog
Recent Announcements
Recent Announcements
博客园 - Franky
N
News | PayPal Newsroom
V
V2EX
A
About on SuperTechFans
The Register - Security
The Register - Security
月光博客
月光博客
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Google Online Security Blog
Google Online Security Blog
MyScale Blog
MyScale Blog
Cisco Talos Blog
Cisco Talos Blog
Vercel News
Vercel News
WordPress大学
WordPress大学
C
Cyber Attacks, Cyber Crime and Cyber Security
The Hacker News
The Hacker News
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog
IntelliJ IDEA : IntelliJ IDEA – the Leading IDE for Professional Development in Java and Kotlin | The JetBrains Blog
爱范儿
爱范儿
A
Arctic Wolf
L
LINUX DO - 最新话题
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More

博客园 - 南国之恋

解决delphi7在win10上安装后无法正常使用的问题 windows服务器C盘空间清理,发现大文件,可用!AutoCleanC_DeepScan - 南国之恋 查看分区表大小 系统表空间清理 postman调用deepseek webapi 将Nginx安装为windows服务,下载nssm 单词系列2 2025高考英语高频易错词汇分类速记 vs2019 本地源“C:\Program Files\DevExpress 22.2\Components\System\Components\Packages”不存在 - 南国之恋 mysql数据库定时事件 plsql查询oracle数据表时,将备注显示成列名 生成脚本 达梦数据库学习记录 oracle密码过期问题,用户锁定问题 mysql odbc delphi连接问题 调用Exe程序并且出现界面 CreateProc(ProcessName:String) c# winform exe.config不能更新 frp(fast reverse proxy)是一款高性能的反向代理应用 GitHub上整理的一些工具 Kettle 中文名称叫水壶
Delphi 7 编译软件申请管理员权限
南国之恋 · 2024-11-28 · via 博客园 - 南国之恋

第一步,建立manifest文件,如xx.manifest 文件内容如下:


<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
<security>
<requestedPrivileges>
<requestedExecutionLevel level="requireAdministrator" uiAccess="false"/>
</requestedPrivileges>
</security>
</trustInfo>
</assembly>


请注意:uiAccess=''false' 是必须要的,如果没有会运行报错:


第二步, 用文本编辑器,新建一个文本文件,填写如下内容,并保存成xx.rc(xx.rc文件和上面的xx.manifest文件放在同一个文件夹下)

1 24 xx.manifest

第三步, 打开dos 命令行,cd到上面两个文件所在的目录,运行如下命令
brcc32 xx.rc -fo xx.res

第四步, 将生成的xx.res 复制到delphi的工程目录下,在程序里引用:

{$R xx.res}

编译。就可以看到应用程序图标自带小盾牌了。

(如果想调试阶段也能申请到管理员权限,用管理员权限运行delphi32.exe)
————————————————

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。

原文链接:https://blog.csdn.net/awski/article/details/48052419