Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Network domain or workgroup
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01369239
Message ID:
01369272
Vues:
7
>OK, last one, What about WMI?
>
loItem.PartOfDomain ===== brought me the right answer of .f. (reason:we don't have a network domain)
loItem.Workgroup ====== brought we the wrong answer of NULL (reason:we run under workgroup network)
loItem.Domain ====== brought me PSYSTEMS (the name of our workgroup)... could be the answer of workgroup property...

I'm not sure under this weird answer if it can be reliable to run under production phase.. What do you think?

>
>loLocator		= CREATEOBJECT('WBEMScripting.SWBEMLocator')
>loWMI			= loLocator.ConnectServer()
>loItems			= loWMI.ExecQuery("Select * from Win32_ComputerSystem")
>
>For Each loItem in loItems
>    ? Iif(loItem.PartOfDomain, "Computer Domain: " + loItem.Domain, "Workgroup: " + loItem.Workgroup)
>Next
>
>
>[Updated]
"Now to him who is able to do immeasurably more than all we ask or imagine, according to his power that is at work within us, Ephesians 3:20
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform