在 Edge IE 模式下禁用个性化您的网络体验

问题描述 投票:0回答:1

如何在使用 selenium 启动 Edge IE 模式时禁用个性化您的 Web 体验提示?

无法在 Edge ie 模式下找到此设置的任何功能。在私有模式下添加 ie 命令行开关不起作用

microsoft-edge
1个回答
0
投票
Here is the code logic to handle the notification

EdgeOptions options = new EdgeOptions();                        
options.addArguments("--start-maximized");      
Map<String, Object> prefs = new LinkedHashMap<>();          
prefs.put("user_experience_metrics.personalization_data_consent_enabled", Boolean.valueOf(true));           
options.setExperimentalOption("prefs", prefs);          
driver = new EdgeDriver(options);
© www.soinside.com 2019 - 2024. All rights reserved.