如何获取Visual Studio 2017的UILanguage用于外部程序 [英] How to get the UILanguage of Visual Studio 2017 for external program

查看:103
本文介绍了如何获取Visual Studio 2017的UILanguage用于外部程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

   在过去,Visual Studio的UILanguage(即Visual Studio 2015)可以从[HKCU \Software \ Microsoft &\\VisualStudio \14.0 \ General]的注册表项[UILanguage]获得。

    In the past, the UILanguage of Visual Studio (i.e. Visual Studio 2015) could be got from the registry key [UILanguage] at [HKCU\Software\Microsoft\VisualStudio\14.0\General].

   从Visual Studio 2017开始,它发生了很大变化,删除了很多注册表,包括上面的注册表。

    From Visual Studio 2017, it changed a lot and removed a lot of registry including the above one.

   对于外部程序,它可以调用
设置配置查询API
 获取Visual Studio 2017的安装信息。但似乎没有功能提供UILanguage的信息。

    For external program, it can invoke the Setup Configuration query API to get the installation information of Visual Studio 2017. But it seems that there is no function provides the information of UILanguage.

   外部程序有没有办法获得Visual Studio 2017的UILanguage?

    Is there any way that external program could get the UILanguage of Visual Studio 2017 ?

推荐答案

您可能想要使用它来代替(.vbs VB脚本):

You may want to use this instead (.vbs VB script):

设置dte = CreateObject(" VisualStudio.DTE.15.0")

MsgBox dte.LocaleId

dte.Quit

Set dte = CreateObject("VisualStudio.DTE.15.0")
MsgBox dte.LocaleId
dte.Quit


这篇关于如何获取Visual Studio 2017的UILanguage用于外部程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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