Wrox Programmer Forums
|
VB How-To Ask your "How do I do this with VB?" questions in this forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 10th, 2005, 11:04 AM
Registered User
 
Join Date: May 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default WMI

Hi

I am new to vb.net. I am trying to access wmi to check hardware on computers. How do I associate WMI into vb.net.

Thanks Dave
 
Old May 11th, 2005, 10:35 PM
Authorized User
 
Join Date: Jul 2003
Posts: 40
Thanks: 0
Thanked 1 Time in 1 Post
Default

Try to look for "ManagementObject Class" in MSDN. This require "System.Management" NameSpace.

 
Old May 18th, 2005, 03:50 AM
Friend of Wrox
 
Join Date: Dec 2004
Posts: 221
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Make a Reference to System.Management Namespace

Dim sd As New ManagementObject("win32_logicaldisk.deviceid=""c:" "")
sd.Get()
MessageBox.Show(sd("Size").ToString())

Hope this helps.

With Regards,
Raghavendra Mudugal





Similar Threads
Thread Thread Starter Forum Replies Last Post
about WMI in C#!!! puppyonline C# 2005 0 March 22nd, 2006 11:42 PM
WMI Classes madda C# 2005 0 January 17th, 2006 06:45 AM
WMI Houghts VB.NET 2002/2003 Basics 2 May 10th, 2005 03:39 PM
Consuming WMI Events skin C# 1 November 22nd, 2004 06:55 PM
port info for WMI sudha1234 .NET Web Services 0 November 17th, 2004 09:09 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.