zoukankan      html  css  js  c++  java
  • 如何获取本机已经安装了的软件的列表?

    using System;
    using Microsoft.Win32;

    namespace ConsoleApplication7
    {
        
    /// <summary>
        
    /// Class1 の概要の説明です。
        
    /// </summary>

        class Class1
        
    {
            
    /// <summary>
            
    /// アプリケーションのメイン エントリ ポイントです。
            
    /// </summary>

            [STAThread]
            
    static void Main(string[] args)
            
    {
                RegistryKey rk 
    = Registry.LocalMachine.OpenSubKey("SOFTWARE");

                PrintKeys(rk);

                Console.ReadLine();
            }


            
    static void PrintKeys(RegistryKey rkey) 
            
    {
                
    // Retrieve all the subkeys for the specified key.
                String [] names = rkey.GetSubKeyNames();

                
    // Print the contents of the array to the console.
                foreach (String s in names) 
                
    {
                    Console.WriteLine(s);
                }

            }

        }

    }
  • 相关阅读:
    主成分分析法
    K-means算法
    高斯混合模型
    data structure test
    八皇后问题求解
    商品管理系统课程设计
    哈佛商学院20部必看电影
    usaco1.1
    Visual Studio 2012 出现关于ActivityLog.xml错误的解决方案
    2012蓝桥杯决赛题
  • 原文地址:https://www.cnblogs.com/sskset/p/153109.html
Copyright © 2011-2022 走看看