Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / October 2006

Tip: Looking for answers? Try searching our database.

Pls Explain Path in this MSDN example

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
andrewcw - 04 Oct 2006 20:01 GMT
Starting with  
http://msdn2.microsoft.com/en-us/library/system.management.managementscope.aspx

' Make a connection to a remote computer.
       ' Replace the "FullComputerName" section of the
       ' string "\\FullComputerName\root\cimv2" with
       ' the full computer name or IP address of the
       ' remote computer.
       Dim scope As ManagementScope
       scope = New ManagementScope( _
           "\\FullComputerName\root\cimv2")
       scope.Connect()

Why is there a cimV2 ? IfI can manually map to \\MyServer\MyShare - and I
can PING myServer ( but not myServer\mySahre ) and the IP address is for
MyShare.

How am I to map | connect  the drive ? If I use \\MyServer\MyShare I get RPC
server not available. -Can someone explain what should be the parameters that
has really tested it ?  Thanks

Signature

Andrew

Dmytro Lapshyn [MVP] - 05 Oct 2006 08:14 GMT
Hi Andrew,

This path is not, well, a path to a network share. Everything behind the
computer name or the IP address followed by the slash is a WMI-specific
notation to designate a specific WMI object or collection on the remote
machine. Hence, in the MSDN example you're referring to, just specify the
correct computer name and leave "\root\cimv2" unchanged.

Speaking of possible troubleshooting, you should rather look into
permissions - if the account under which your sample runs does not have
administrative privileges on the remote machine, access might be denied.

Signature

Regards,
Dmytro Lapshyn [MVP]
http://blogs.vbcity.com/DmytroL

> Starting with
> http://msdn2.microsoft.com/en-us/library/system.management.managementscope.aspx
[quoted text clipped - 18 lines]
> that
> has really tested it ?  Thanks
andrewcw - 05 Oct 2006 14:49 GMT
Dmytro,  Thanks for clarifying the mysterious use of \root\cimv2 - I am
deeply puzzled over the lack of enterprise .NET support as I see it.  Large
companies like the one I work for ' rent ' out ComputerName\ShareName.  We
can map to these drives if we have permission. And then move files as needed.
With VB 6 the object funcionality is cleanly exposed with COM via the Window
Scripting Host.  While its true I can make an Interop Assembly just to do
this function,  I think that both WSH and WMI have common cores ( both COM ).
 Is there no other way ?  

Lastly  Is there a way to let MS know that building out a whole class file
encapsulating WIN 32 or making interop asseblies  just to do this function is
- silly ! - when the same capability is exposed nicely for a different
process ( exe ) with this :
System.Diagnostics.Process.Start(filename,username, password, domain) ?

Signature

Andrew

> Hi Andrew,
>
[quoted text clipped - 30 lines]
> > that
> > has really tested it ?  Thanks

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.