Click here to Skip to main content
15,890,123 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
VB
Public Sub New()
            Dim wmins = ("//192.168.1.5/root/cimv2")
            objOS = New ManagementObjectSearcher(wmins, "SELECT * FROM Win32_OperatingSystem ")
            objCS = New ManagementObjectSearcher(wmins, "SELECT * FROM Win32_ComputerSystem")
            objPR = New ManagementObjectSearcher(wmins, "SELECT * FROM Win32_Processor")
            objHS = New ManagementObjectSearcher(wmins, "SELECT * FROM Win32_DiskDrive")
            objIS = New ManagementObjectSearcher(wmins, "SELECT * FROM Win32_Product")
            For Each objMgmt In objOS.Get
                         The error is:  Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))

               
                m_strOSName = objMgmt("name").ToString()
                m_strOSVersion = objMgmt("version").ToString()
                m_strComputerName = objMgmt("csname").ToString()
                m_strWindowsDir = objMgmt("windowsdirectory").ToString()
            Next


I just want to list all installed software's on my local area systems that's all
Posted
Updated 24-Mar-12 3:06am
v2

1 solution

All web applications run within an application pool which defines the parameters around the executable process that is used to execute the code within the web application. This is true regardless of whether you are running a standard .Net app or within SharePoint or any software.

1. Login to your Virtual Machine using Remote Desktop ( mstsc )
2. Go to "C:\os\etc\DiskSecurity" folder
3. Edit disksecurity.xml file. Add following entry at the end ( before </Entries> )
<Entry AccounType="1" Account="Psacln" Path="C:\Windows\assembly" AceFlags="FilesOnly" AccessMask="Read" EntryFlags="0x0" />
4. Save. And you are done
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900