如何使我的c ++ win32安装程序无声 [英] how to make my c++ win32 installer silent

查看:59
本文介绍了如何使我的c ++ win32安装程序无声的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使我的c ++ win32 .Net框架安装程序(包括3个exe文件)无声,

(形式:Windows)



我试过sfxmaker软件& ussf.exe,但是我得到了未知的安装程序错误...



命令行参数/ S和/ SD对我来说也不起作用...



我使用的部分代码:



  if (!CreateProcess(NULL, //  无模块名称(使用命令行) 
。\\InstallationFiles \\dotnetfx 35 SP1 Full.exe / S
NULL, // 流程句柄不可继承
NULL,< span class =code-comment> // 线程句柄不可继承
FALSE, / / 将句柄继承设置为FALSE
0 // 无创建标志
NULL , // 使用父级的环境块
NULL, // 使用父的起始目录
& si, // < span class =code-comment>指向STARTUPINFO结构的指针
& pi) // 指向PROCESS_INFORMATION结构的指针









请帮忙,



提前谢谢

解决方案

我知道了,谢谢大家,

我的解决方案是:



if(!CreateProcess(NU) LL,//没有模块名称(使用命令行)

.\\InstallationFiles\\dotnetfx35SP1Full.exe / Q / norestart更新日志文件/ ChainingPackage ADMINDEPLOYMENT,... //我提到只有2个参数。



检查一下:

http://msdn.microsoft.com/en-us/library/ee390831(v=vs.100).aspx [ ^ ]





注意:但朋友们在桌面上看不到任何改进,请检查任务管理器是否可以查看。


< blockquote>在今天的系统中,这实际上并不实用(或者甚至可行)...主要原因是,即使用户是管理员,大多数系统也会在较低的权限级别下运行大多数应用程序。这当然是出于安全原因,但其含义是,任何必须对系统进行更改的内容(注册表或系统文件夹)都必须明确要求用户许可。正如您所看到的,在这些条件下使安装程序无声几乎是不可能的。



这适用于现代Windows和Linux系统。


how to make my c++ win32 .Net frameworks installer(include 3 exe files) silent,
(paltform: Windows)

I tried sfxmaker software & ussf.exe, but i get unknown installer error...

command line arguments /S and /SD also not working for me...

part of code I use :

if( !CreateProcess( NULL,   // No module name (use command line)
                  ".\\InstallationFiles\\dotnetfx 35 SP1 Full.exe/S",
                  NULL,           // Process handle not inheritable
                  NULL,           // Thread handle not inheritable
                  FALSE,          // Set handle inheritance to FALSE
                  0,              // No creation flags
                  NULL,           // Use parent's environment block
                  NULL,           // Use parent's starting directory
                  &si,            // Pointer to STARTUPINFO structure
                  &pi )           // Pointer to PROCESS_INFORMATION structure
                  )





Please help,

Thanks in advance

解决方案

I got it, Thanks to all,
My solution is:

if( !CreateProcess ( NULL, // No module name (use command line)
".\\InstallationFiles\\dotnetfx35SP1Full.exe /q /norestart /ChainingPackage ADMINDEPLOYMENT",... // I mentioned only 2 arguments.

Check this too:
http://msdn.microsoft.com/en-us/library/ee390831(v=vs.100).aspx[^]


NOTE: but friends you will not see any improvement on the desk, check task manager to view it.


This is really not practical (or maybe even doable) in today''s systems... main reason is that most systems run most applications under lower permission levels even if the user is an administrator. This of course is for safety reasons, but the implication of this is that anything that has to do changes to the system (either registry or system folders) has to ask for permission from the user explicitly. As you can see, it becomes almost impossible to make an installer "silent" under those conditions.

This applies to both modern Windows and Linux systems.


这篇关于如何使我的c ++ win32安装程序无声的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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