<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Mehr Infos mit NetWkstaGetInfo]]></title><description><![CDATA[<p>Ich brauche Betriebssysteminformationen von einem Remoterechner. Dazu nutze ich die API-Funktion <em>NetWkstaGetInfo</em>. Damit bekomme ich aber leider nur die Major- und Minor-Versionsnummer. Das reicht aber leider nicht aus, um zum Beispiele zwischen Windows XP Professional und Windows XP Home zu unterscheiden. Es wäre für mein Programm aber ziemlich wichtig zu wissen, ob auf dem Remoterechner XP Home oder XP Professional läuft. Und ich meine, ich hätte schon Programme gesehen, die das können.</p>
<p>Oder gibt es eine andere möglicheit das Betriebssystem eines Remoterehners zu ermitteln, ohne dass dort ein Client läuft, der einem die gewünschten Informationen zurückschickt?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/187266/mehr-infos-mit-netwkstagetinfo</link><generator>RSS for Node</generator><lastBuildDate>Sat, 04 Jul 2026 11:18:43 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/187266.rss" rel="self" type="application/rss+xml"/><pubDate>Tue, 17 Jul 2007 19:41:35 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Mehr Infos mit NetWkstaGetInfo on Tue, 17 Jul 2007 19:41:35 GMT]]></title><description><![CDATA[<p>Ich brauche Betriebssysteminformationen von einem Remoterechner. Dazu nutze ich die API-Funktion <em>NetWkstaGetInfo</em>. Damit bekomme ich aber leider nur die Major- und Minor-Versionsnummer. Das reicht aber leider nicht aus, um zum Beispiele zwischen Windows XP Professional und Windows XP Home zu unterscheiden. Es wäre für mein Programm aber ziemlich wichtig zu wissen, ob auf dem Remoterechner XP Home oder XP Professional läuft. Und ich meine, ich hätte schon Programme gesehen, die das können.</p>
<p>Oder gibt es eine andere möglicheit das Betriebssystem eines Remoterehners zu ermitteln, ohne dass dort ein Client läuft, der einem die gewünschten Informationen zurückschickt?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1327426</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1327426</guid><dc:creator><![CDATA[[[global:former_user]]]]></dc:creator><pubDate>Tue, 17 Jul 2007 19:41:35 GMT</pubDate></item><item><title><![CDATA[Reply to Mehr Infos mit NetWkstaGetInfo on Wed, 18 Jul 2007 06:22:18 GMT]]></title><description><![CDATA[<p>z.B. mittels<br />
- WMI<br />
oder<br />
- Remote-Registry-Access</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1327519</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1327519</guid><dc:creator><![CDATA[Jochen Kalmbach]]></dc:creator><pubDate>Wed, 18 Jul 2007 06:22:18 GMT</pubDate></item><item><title><![CDATA[Reply to Mehr Infos mit NetWkstaGetInfo on Wed, 18 Jul 2007 09:20:35 GMT]]></title><description><![CDATA[<p>WMI wäre eine Möglichkeit, daran habe ich noch gar nicht gedacht. Aber Remote-Registry-Access geht nicht, da XP Home keinen Remotezugriff der Registry zu lässt. Genau deswegen muss ich ja wissen, ob es Home oder Professinal ist, weil ich Zugriff auf die Registry brauche. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /> Aber zu sagen &quot;kein Zugriff, ergo Home&quot; ist auch nicht sicher. Aber mit WMI werde ich es mal testen. Danke für den Tipp.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1327619</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1327619</guid><dc:creator><![CDATA[[[global:former_user]]]]></dc:creator><pubDate>Wed, 18 Jul 2007 09:20:35 GMT</pubDate></item><item><title><![CDATA[Reply to Mehr Infos mit NetWkstaGetInfo on Wed, 18 Jul 2007 10:12:51 GMT]]></title><description><![CDATA[<p>Per WMI...</p>
<pre><code>uses
  WbemScripting_TLB, ActiveX;

type
  TWMIOSInfo = record
    OSVersionString: string;
    CSDVersion: string;
    OSManufacturer: string;
  end;

const
  WMI_SYSTEM_NAMESPACE = 'root\CIMV2';
  WMI_CLASS_OS = 'Win32_OperatingSystem';
  WMI_ATTRIB_OSCAPTION = 'Caption';
  WMI_ATTRIB_CSDVERSION = 'CSDVersion';
  WMI_ATTRIB_OSMAN = 'Manufacturer';

function WMIGetOSInfo(const Computer, user, Password: string): TWMIOSInfo;
var
  Locator      : ISWbemLocator;
  Services     : ISWbemServices;
  ObjectDefinition: ISWbemObject;
  ObjectSet    : SWbemObjectSet;
  ObjectInstances: IEnumVariant;
  WMIObject    : ISWbemObject;
  PropertySet  : ISWbemPropertySet;
  WMIProperty  : ISWbemProperty;

  TempObj      : OleVariant;
  ObjValue     : Cardinal;
begin
  Locator := CoSWbemLocator.CreateRemote(Computer);
  try
    try
      Services := Locator.ConnectServer(Computer, WMI_SYSTEM_NAMESPACE, User,
        Password, '', '', 0, nil);
      if Services &lt;&gt; nil then
      begin
        ObjectDefinition := Services.Get(WMI_CLASS_OS,
          wbemFlagUseAmendedQualifiers, nil);
        ObjectSet := ObjectDefinition.Instances_(0, nil);
        ObjectInstances := (ObjectSet._NewEnum) as IEnumVariant;
        if ObjectInstances.Next(1, TempObj, ObjValue) = S_OK then
        begin
          WMIObject := IUnknown(TempObj) as SWBemObject;
          PropertySet := WMIObject.Properties_;
          WMIProperty := PropertySet.Item(WMI_ATTRIB_OSCAPTION, 0);
          if not VarIsNull(WMIProperty.Get_Value) then
            result.OSVersionString := trim(WMIProperty.Get_Value);
          WMIProperty := PropertySet.Item(WMI_ATTRIB_CSDVERSION, 0);
          if not VarIsNull(WMIProperty.Get_Value) then
            result.CSDVersion := trim(WMIProperty.Get_Value);
          WMIProperty := PropertySet.Item(WMI_ATTRIB_OSMAN, 0);
          if not VarIsNull(WMIProperty.Get_Value) then
            result.OSManufacturer := trim(WMIProperty.Get_Value);
        end;
      end;
    finally
      Locator := nil;
      Services := nil;
    end;
  except
    on e: Exception do
      e.Create(e.Message);
  end;
end;
</code></pre>
<p>...bekomme ich leider den Fehler &quot;Zugriff verweigert&quot;.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1327664</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1327664</guid><dc:creator><![CDATA[[[global:former_user]]]]></dc:creator><pubDate>Wed, 18 Jul 2007 10:12:51 GMT</pubDate></item></channel></rss>