.net 谷歌浏览器在哪里存储我的主页?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/4529650/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-03 15:04:11  来源:igfitidea点击:

Where does Google Chrome store my homepage?

.netvb.netgoogle-chrome

提问by user539493

I located the Profiles folder for Chrome, but I'm unable to find any file which stores my homepage.

我找到了 Chrome 的 Profiles 文件夹,但找不到任何存储我的主页的文件。

Basically I want to change my Chrome homepage using VB.NET, but I can't find where it is stored. I have already checked the Registry and in the Profiles folder.

基本上我想使用 VB.NET 更改我的 Chrome 主页,但我找不到它的存储位置。我已经检查了注册表和 Profiles 文件夹。

Any help would be appreciated.

任何帮助,将不胜感激。

回答by Cody Gray

A quick glance at the documentation concerning the User Data Directorytells us that Chrome stores information and parameters for specific users in the following locations:

快速浏览有关用户数据目录的文档告诉我们,Chrome 将特定用户的信息和参数存储在以下位置:

Windows XP
C:\Documents and Settings\<username>\Local Settings\Application Data\Google\Chrome\User Data\Default

Windows Vista
C:\Users\<username>\AppData\Local\Google\Chrome\User Data\Default

视窗 XP
C:\Documents and Settings\<username>\Local Settings\Application Data\Google\Chrome\User Data\Default

视窗Vista
C:\Users\<username>\AppData\Local\Google\Chrome\User Data\Default

In that folder, you'll find a file named "Preferences". The file is saved in JSON format. You can open this file as plain text, search for the string "homepage", and modify one or both of the settings. The first one indicates what Chrome uses as your homepage. The second indicates whether Chrome automatically opens the "New Tab" page (True), or if it navigates to your specified homepage (False).

在该文件夹中,您会找到一个名为“首选项”的文件。该文件以JSON 格式保存。您可以以纯文本形式打开此文件,搜索字符串“主页”,然后修改其中一项或两项设置。第一个指示 Chrome 用作主页的内容。第二个指示 Chrome 是自动打开“新标签”页面 (True),还是导航到您指定的主页 (False)。

For example, the relevant two lines in my "Preferences" file look like this:

例如,我的“首选项”文件中相关的两行如下所示:

"homepage": "http://www.google.com/",
"homepage_is_newtabpage": true,

回答by Khairul Ikhwan

I found that we can Chrome homepage from entry point of the browser itself. But perhaps your application should be getting admin's permission in that particular machine.

我发现我们可以从浏览器本身的入口点访问 Chrome 主页。但也许您的应用程序应该在该特定机器上获得管理员的许可。

If Im not mistaken, you can set in vb.net so that the app will automatically ask for admin's permission (UAC)

如果我没记错的话,你可以在 vb.net 中设置,这样应用程序会自动请求管理员的许可(UAC)

回答by TechGuru

I like using the adm file from chromium.org.

我喜欢使用来自chromium.org 的adm 文件。

Download from here.

这里下载。

Just set your home page via GPO and link it to the OU with the computers.

只需通过 GPO 设置您的主页并将其链接到计算机的 OU。

Computer Configuration\Policies\Administrative Templates\Classic Administrative Templates (ADM)\Google\Google Chrome\Home page\ Configure the home page URL = enabled

Computer Configuration\Policies\Administrative Templates\Classic Administrative Templates (ADM)\Google\Google Chrome\Home page\ 配置主页 URL = enabled

or if you want your users to be able to change it

或者如果您希望您的用户能够更改它

Computer Configuration\Policies\Administrative Templates\Classic Administrative Templates (ADM)\Google\Google Chrome - Default Settings (users can override)\Home page\ Configure the home page URL = enabled

计算机配置\策略\管理模板\经典管理模板 (ADM)\Google\Google Chrome - 默认设置(用户可以覆盖)\主页\ 配置主页 URL = 已启用