WiX ManagedBootstrapper SetDownloadSource 混乱 [英] WiX ManagedBootstrapper SetDownloadSource confusion

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

问题描述

我对 Engine.SetDownloadSource() 方法有点困惑.我想要做的是将捆绑包的下载 URL 从外部网站更改为内部网站.(如果有更简单的方法可以做到这一点,我愿意接受其他建议).

I am a bit confused by the method Engine.SetDownloadSource(). What I am trying to do is change the download URL for the bundled packages from an external website to an internal one. (If there is an easier way to do this, I am open to other suggestions).

现在解决问题.调用此方法时,它要求输入用户和密码.我不确定应该从哪里获得这些信息.

Now for the problem. When calling this method it is asking for a user and password. I am not sure where I should get this info from.

string downloadSource = Path.Combine(WebSitePath(), "WebSetup/WebSetupData/", Path.GetFileName(args.DownloadSource));

Engine.SetDownloadSource(args.PackageOrContainerId, args.PayloadId, downloadSource, user, password);

WebSitePath() 只返回网站的基本 URL.如果我不更改链接,我找不到关于 MBA 将使用什么用户名和密码的任何提示,同样我不确定如何告诉它使用当前的 Windows 用户从新链接下载.任何帮助将不胜感激.

WebSitePath() simply returns the base URL for the website. I can't find any hint about what username and password the MBA would use if I didn't change the link, and likewise I am not sure how to tell it to use the current windows user to download from the new link. Any help would be greatly appreciated.

推荐答案

用户名和密码是可选的,以支持基本或摘要式 HTTP 授权.如果您不想提供用户/密码组合,请将它们设置为 null.

Username and password are optional to support basic or digest HTTP authorization. Set them to null if you don't want to provide a user/password combination.

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

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