<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="/rss.xsl"?><rss version="2.0"><channel><title>linq2wmi Forum Rss Feed</title><link>http://www.codeplex.com/linq2wmi/Thread/List.aspx</link><description>linq2wmi Forum Rss Description</description><item><title>New Post: Win32_NetworkAdapterConfiguration</title><link>http://linq2wmi.codeplex.com/discussions/397829</link><description>&lt;div style="line-height: normal;"&gt;
&lt;p&gt;&lt;span id="result_box" lang="en"&gt;&amp;nbsp; &lt;span&gt;Hello, &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span id="result_box" lang="en"&gt;&lt;span&gt;I generated&lt;/span&gt; &lt;/span&gt;&lt;span id="result_box" lang="en"&gt;&lt;span&gt;Win32_NetworkAdapterConfiguration class
&lt;/span&gt;&lt;/span&gt;&lt;span id="result_box" lang="en"&gt;&lt;span&gt;with&lt;/span&gt; &lt;span&gt;LinqToWmi.ClassGenerator&lt;/span&gt;
&lt;span&gt;.&lt;/span&gt;&lt;br&gt;
&lt;span&gt;I've included&lt;/span&gt; &lt;span&gt;the generated file into&lt;/span&gt; &lt;span&gt;my c# solution.&lt;/span&gt;&lt;br&gt;
&lt;span&gt;However, I&lt;/span&gt; &lt;span&gt;can not&lt;/span&gt; &lt;span&gt;get my&lt;/span&gt; &lt;span&gt;IP address using&lt;/span&gt;
&lt;span&gt;Win32_NetworkAdapterConfiguration&lt;/span&gt;&lt;span&gt;.&lt;/span&gt;&lt;br&gt;
&lt;span&gt;How can I do?&lt;/span&gt;&lt;br&gt;
&lt;span&gt;Thank you.&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;/div&gt;</description><author>titi14</author><pubDate>Wed, 03 Oct 2012 06:37:27 GMT</pubDate><guid isPermaLink="false">New Post: Win32_NetworkAdapterConfiguration 20121003063727A</guid></item><item><title>New Post: Querying remote hosts not working?</title><link>http://linq2wmi.codeplex.com/discussions/249846</link><description>&lt;div style="line-height: normal;"&gt;&lt;p&gt;Thank you DBaines!&lt;/p&gt;&lt;/div&gt;</description><author>aderuwe</author><pubDate>Wed, 21 Sep 2011 22:07:21 GMT</pubDate><guid isPermaLink="false">New Post: Querying remote hosts not working? 20110921100721P</guid></item><item><title>New Post: Querying remote hosts not working?</title><link>http://linq2wmi.codeplex.com/discussions/249846</link><description>&lt;div style="line-height: normal;"&gt;&lt;blockquote style="padding-right: 0.25em; padding-left: 0.25em; padding-bottom: 0px; margin: 0.25em 1em 0px; padding-top: 0px; font-style: italic; border: #ccc 0.1em solid;"&gt;&lt;strong&gt;aderuwe wrote:&lt;/strong&gt;&lt;br /&gt;
&lt;p&gt;&amp;nbsp;&lt;span style="color: #000000;"&gt;Trying to query a remote host is not working for me. &amp;nbsp;In testing, I'm using the following:&lt;span style="color: #0000ff;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color: blue;"&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color: blue;"&gt;using&lt;/span&gt; (WmiContext context = &lt;span style="color: blue;"&gt;new&lt;/span&gt; WmiContext(&lt;span style="color: #a31515;"&gt;@"\\A_Remote_Machine"&lt;/span&gt;))&lt;br /&gt;{&lt;br /&gt; context.ManagementScope.Options.Impersonation = ImpersonationLevel.Impersonate;&lt;br /&gt; context.Log = Console.Out;&lt;br /&gt; QueryProcessors(context);&lt;br /&gt;}&lt;/p&gt;
&lt;p&gt;I found that when you specify the WmiContext constructor with a suffix of the namespace you are connecting to everything works. So:&lt;/p&gt;
&lt;p&gt;&lt;span style="color: blue;"&gt;using&lt;/span&gt; (WmiContext context = &lt;span style="color: blue;"&gt;new&lt;/span&gt; WmiContext(&lt;span style="color: #a31515;"&gt;@&lt;a href="file://\\A_Remote_Machine\root\cimv2"&gt;\\A_Remote_Machine\root\cimv2&lt;/a&gt;&lt;/span&gt;))&lt;/p&gt;
&lt;p&gt;Is the ticket!&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;div style="color: black; background-color: white;"&gt;
&lt;pre style="color: black;"&gt;&lt;div style="color: black; background-color: white;"&gt;&amp;nbsp;&lt;/div&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;/blockquote&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;</description><author>DBaines</author><pubDate>Wed, 25 May 2011 16:20:08 GMT</pubDate><guid isPermaLink="false">New Post: Querying remote hosts not working? 20110525042008P</guid></item><item><title>New Post: Querying remote hosts not working?</title><link>http://linq2wmi.codeplex.com/discussions/249846</link><description>&lt;div style="line-height: normal;"&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;div style="color:black; background-color:white"&gt;
&lt;pre&gt;&lt;span style="color:#000000"&gt;Trying to query a remote host is not working for me. &amp;nbsp;In testing, I'm using the following:&lt;span style="color:#0000ff"&gt;&lt;br&gt;&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="color:black"&gt;&lt;span style="color:blue"&gt;&lt;br&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre style="color:black"&gt;&lt;span style="color:blue"&gt;using&lt;/span&gt; (WmiContext context = &lt;span style="color:blue"&gt;new&lt;/span&gt; WmiContext(&lt;span style="color:#a31515"&gt;@&amp;quot;\\A_Remote_Machine&amp;quot;&lt;/span&gt;))
{
	context.ManagementScope.Options.Impersonation = ImpersonationLevel.Impersonate;
	context.Log = Console.Out;
	QueryProcessors(context);
}
&lt;/pre&gt;
&lt;pre style="color:black"&gt;&lt;div style="color:black; background-color:white"&gt;&lt;pre&gt;&lt;span style="color:blue"&gt;private&lt;/span&gt; &lt;span style="color:blue"&gt;static&lt;/span&gt; &lt;span style="color:blue"&gt;void&lt;/span&gt; QueryProcessors(WmiContext context)
{
	&lt;span style="color:blue"&gt;var&lt;/span&gt; query = &lt;span style="color:blue"&gt;from&lt;/span&gt; processor &lt;span style="color:blue"&gt;in&lt;/span&gt; context.Source&amp;lt;Win32_Processor&amp;gt;()
			&lt;span style="color:blue"&gt;select&lt;/span&gt; processor;

	&lt;span style="color:blue"&gt;foreach&lt;/span&gt; (Win32_Processor processor &lt;span style="color:blue"&gt;in&lt;/span&gt; query)
	{
		Console.WriteLine(String.Format(&lt;span style="color:#a31515"&gt;&amp;quot;DeviceID: {0}&amp;quot;&lt;/span&gt;, processor.DeviceID));
		Console.WriteLine(String.Format(&lt;span style="color:#a31515"&gt;&amp;quot;Speed: {0} mhz&amp;quot;&lt;/span&gt;, processor.CurrentClockSpeed));
		Console.WriteLine(String.Format(&lt;span style="color:#a31515"&gt;&amp;quot;Usage: {0}%&amp;quot;&lt;/span&gt;, processor.LoadPercentage));
	}
}
&lt;/pre&gt;
&lt;/div&gt;
&lt;br&gt;&lt;/pre&gt;
&lt;pre style="color:black"&gt;I'm getting the local processor, not the processor from A_Remote_Machine.  Any ideas?&lt;/pre&gt;
&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;/div&gt;</description><author>aderuwe</author><pubDate>Tue, 15 Mar 2011 22:38:27 GMT</pubDate><guid isPermaLink="false">New Post: Querying remote hosts not working? 20110315103827P</guid></item><item><title>New Post: Project dead?</title><link>http://linq2wmi.codeplex.com/Thread/View.aspx?ThreadId=42140</link><description>&lt;div style="line-height: normal;"&gt;
&lt;p&gt;Project has been revived if it still matters to you.&lt;/p&gt;
&lt;/div&gt;</description><author>hype8912</author><pubDate>Sat, 08 Jan 2011 00:24:53 GMT</pubDate><guid isPermaLink="false">New Post: Project dead? 20110108122453A</guid></item><item><title>New Post: Non-default namespace classes</title><link>http://linq2wmi.codeplex.com/Thread/View.aspx?ThreadId=231326</link><description>&lt;div style="line-height: normal;"&gt;This discussion has been copied to a work item. Click &lt;a href="http://linq2wmi.codeplex.com/workitem/19618"&gt;here&lt;/a&gt; to go to the work item and continue the discussion.&lt;/div&gt;</description><author>hype8912</author><pubDate>Sat, 08 Jan 2011 00:24:10 GMT</pubDate><guid isPermaLink="false">New Post: Non-default namespace classes 20110108122410A</guid></item><item><title>New Post: How to update linq to wmi for SubmitChange()?</title><link>http://linq2wmi.codeplex.com/Thread/View.aspx?ThreadId=39639</link><description>&lt;div style="line-height: normal;"&gt;This discussion has been copied to a work item. Click &lt;a href="http://linq2wmi.codeplex.com/workitem/19617"&gt;here&lt;/a&gt; to go to the work item and continue the discussion.&lt;/div&gt;</description><author>hype8912</author><pubDate>Sat, 08 Jan 2011 00:23:20 GMT</pubDate><guid isPermaLink="false">New Post: How to update linq to wmi for SubmitChange()? 20110108122320A</guid></item><item><title>New Post: How to update linq to wmi for SubmitChange()?</title><link>http://linq2wmi.codeplex.com/Thread/View.aspx?ThreadId=39639</link><description>&lt;div style="line-height: normal;"&gt;
&lt;p&gt;I know this is an old post but I have just been added to the project and this is one of the things I've been working on. You should see this in the coming future.&lt;/p&gt;
&lt;/div&gt;</description><author>hype8912</author><pubDate>Sat, 08 Jan 2011 00:21:57 GMT</pubDate><guid isPermaLink="false">New Post: How to update linq to wmi for SubmitChange()? 20110108122157A</guid></item><item><title>New Post: Non-default namespace classes</title><link>http://linq2wmi.codeplex.com/Thread/View.aspx?ThreadId=231326</link><description>&lt;div style="line-height: normal;"&gt;&lt;p&gt;Hi, first - thanks for this nice project.&lt;/p&gt;
&lt;p&gt;I have a need to access non standard (aka not root\cimv2) wmi namespaces. I modified a copy of the code to be able to handle this. For reference the only changes I had to make are:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Arguments.cs (adding)&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;div style="color:black;background-color:white"&gt;
&lt;pre&gt;&lt;span style="color:blue"&gt;private&lt;/span&gt; &lt;span style="color:blue"&gt;string&lt;/span&gt; _wmiNs = &lt;span style="color:#a31515"&gt;&amp;quot;root\\cimv2&amp;quot;&lt;/span&gt;;

[Argument(&lt;span style="color:#a31515"&gt;&amp;quot;wmins&amp;quot;&lt;/span&gt;, HelpText = &lt;span style="color:#a31515"&gt;&amp;quot;WMI namespace for class for!&amp;quot;&lt;/span&gt;)]
        &lt;span style="color:blue"&gt;public&lt;/span&gt; &lt;span style="color:blue"&gt;string&lt;/span&gt; WmiNs
        {
            &lt;span style="color:blue"&gt;get&lt;/span&gt; { &lt;span style="color:blue"&gt;return&lt;/span&gt; _wmiNs; }
            &lt;span style="color:blue"&gt;set&lt;/span&gt; { _wmiNs = value; }
        }
&lt;/pre&gt;
&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;WmiObjectQuery.cs (changes)&lt;/strong&gt;&lt;/p&gt;
&lt;pre&gt;&lt;span style="color:blue"&gt;public&lt;/span&gt; ManagementObject GetMetaInformation(&lt;span style="color:blue"&gt;string&lt;/span&gt; name, &lt;span style="color:blue"&gt;string&lt;/span&gt; nameSpace)
        {
            ManagementObject value = &lt;span style="color:blue"&gt;null&lt;/span&gt;;
            ManagementScope scope = &lt;span style="color:blue"&gt;new&lt;/span&gt; ManagementScope(&lt;span style="color:#a31515"&gt;@&amp;quot;\\localhost\&amp;quot;&lt;/span&gt; + nameSpace);

            ManagementPath path = &lt;span style="color:blue"&gt;new&lt;/span&gt; ManagementPath(name);
            ManagementClass management = &lt;span style="color:blue"&gt;new&lt;/span&gt; ManagementClass(scope, path, &lt;span style="color:blue"&gt;null&lt;/span&gt;);
   
            &lt;span style="color:blue"&gt;foreach&lt;/span&gt; (ManagementObject child &lt;span style="color:blue"&gt;in&lt;/span&gt; management.GetInstances())
            {            
                value = child;
                &lt;span style="color:blue"&gt;break&lt;/span&gt;;
            }
            management.Dispose();
            &lt;span style="color:blue"&gt;return&lt;/span&gt; value;
        }&lt;br&gt;&lt;br&gt;[Update:] forgot to add an example. Querying the WMI objects for BizTalk would look like this:&lt;br&gt;&amp;nbsp; LinqToWmi.ClassGenerator.exe /wmi:MSBTS_HostInstance /wmins:root\MicrosoftBizTalkServer&lt;/pre&gt;&lt;/div&gt;</description><author>RudolfHenning</author><pubDate>Mon, 18 Oct 2010 13:42:38 GMT</pubDate><guid isPermaLink="false">New Post: Non-default namespace classes 20101018014238P</guid></item><item><title>New Post: Project dead?</title><link>http://www.codeplex.com/linq2wmi/Thread/View.aspx?ThreadId=42140</link><description>&lt;div style="line-height: normal;"&gt;Is there anyone here?&lt;br&gt;
&lt;br&gt;
If so, what is the prospective release date for 0.5?&lt;br&gt;
&lt;br&gt;
       -Steve
&lt;/div&gt;</description><author>shammah</author><pubDate>Fri, 12 Dec 2008 15:32:08 GMT</pubDate><guid isPermaLink="false">New Post: Project dead? 20081212033208P</guid></item><item><title>New Post: How to update linq to wmi for SubmitChange()?</title><link>http://www.codeplex.com/linq2wmi/Thread/View.aspx?ThreadId=39639</link><description>&lt;div style="line-height: normal;"&gt;I want to change my ipaddress with linq to wmi,but I do not know how to update linq to wmi for SubmitChange.&lt;br&gt;
WmiContext context = new WmiContext(@&amp;quot;\\.&amp;quot;);&lt;br&gt;
    var ipaddress = from ip in context.Source&amp;lt;Win32_NetworkAdapterConfiguration&amp;gt;() select ip;&lt;br&gt;
            foreach (Win32_NetworkAdapterConfiguration ip in ipaddress)&lt;br&gt;
            {&lt;br&gt;
                if (ip.IPAddress != null)&lt;br&gt;
                {&lt;br&gt;
                    ip.IPAddress.SetValue(&amp;quot;192.168.8.20&amp;quot;, 0);&lt;br&gt;
&lt;br&gt;
                 //how to SubmitChange?&lt;br&gt;
                }&lt;br&gt;
            }&lt;br&gt;
&lt;br&gt;
    My email:niphone@live.cn&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;</description><author>ncfjj</author><pubDate>Tue, 11 Nov 2008 00:45:41 GMT</pubDate><guid isPermaLink="false">New Post: How to update linq to wmi for SubmitChange()? 20081111124541A</guid></item><item><title>New Post: Generating Common Classes</title><link>http://www.codeplex.com/linq2wmi/Thread/View.aspx?ThreadId=32744</link><description>&lt;div style="line-height: normal;"&gt;&lt;p&gt;As of changeset 21374, you can now generate the &amp;quot;Common&amp;quot; classes by using &amp;quot;Common&amp;quot; in the wmi argument instead of the name of an actual WMI class: /wmi:Common&lt;/p&gt;
&lt;p&gt;The current &amp;quot;Common&amp;quot; classes are:&lt;/p&gt;
&lt;blockquote&gt;            &amp;quot;Win32_ComputerSystem&amp;quot;, &amp;quot;Win32_FloppyDrive&amp;quot;, &amp;quot;Win32_Keyboard&amp;quot;, &amp;quot;Win32_LogicalDisk&amp;quot;, &amp;quot;Win32_NetworkAdapter&amp;quot;,&lt;br&gt;
&amp;quot;Win32_NetworkConnection&amp;quot;, &amp;quot;Win32_OperatingSystem&amp;quot;, &amp;quot;Win32_PointingDevice&amp;quot;, &amp;quot;Win32_Printer&amp;quot;, &amp;quot;Win32_Process&amp;quot;,&lt;br&gt;
&amp;quot;Win32_Processor&amp;quot;, &amp;quot;Win32_Product&amp;quot;, &amp;quot;Win32_UserAccount&amp;quot;&lt;br&gt;
&lt;/blockquote&gt;
&lt;p&gt;If anyone has any suggestions for WMI classes to add to this list, please let me know.&lt;/p&gt;
&lt;/div&gt;</description><author>Atrophius</author><pubDate>Fri, 01 Aug 2008 16:53:41 GMT</pubDate><guid isPermaLink="false">New Post: Generating Common Classes 20080801045341P</guid></item><item><title>New Post: Understanding WMI</title><link>http://www.codeplex.com/linq2wmi/Thread/View.aspx?ThreadId=32097</link><description>&lt;div style="line-height: normal;"&gt;Since WMI is huge, before you can just dive into using Linq2WMI it would be best to at least understand the api and the technology behind it. Here's a really good resource that looks at WMI, the code samples are written in VB.NET but it still pretty useful.&lt;br&gt;
&lt;br&gt;
&lt;a href="http://www.mcwtech.com/2006/vslive/orlando/WMI.pdf"&gt;WMI.pdf&lt;/a&gt; (Powerpoint Slides)&lt;br&gt;
&lt;a href="http://www.mcwtech.com/2006/vslive/orlando/WMI.zip"&gt;Demo Code&lt;/a&gt;&lt;br&gt;
&lt;br&gt;
This comes from a VS2005 Tech Conference (VSLive!) that was presented in Orlando in 2006. [&lt;a href="http://www.mcwtech.com/2006/vslive/orlando/"&gt;via this site&lt;/a&gt;]&lt;br&gt;
&lt;/div&gt;</description><author>nyxtom</author><pubDate>Wed, 23 Jul 2008 15:48:24 GMT</pubDate><guid isPermaLink="false">New Post: Understanding WMI 20080723034824P</guid></item></channel></rss>