Server information queries in ASP.net
Hi, I am trying to make a small webpage which will tell me a thing about the server it is running on, (kind of like how the HP jetdirect Server will tell you stuff about your printer).
in C# you could do a WMI query using System.Management; ManagementObject
However the management object seems not to be recognised in ASP.net.
to be honest, I am not entirely sure how IIS runs the web pages that it displays, does it keep them entirely contained with no access outside its own directory?
The kind of things I am after are like HDD capacity, percentage used, CPU usage of the server. And eventually a remote file browser of the HDD. Are these thing possible in ASP if so how.
Thanks.
PS: what is the best IDE to develop ASP pages, I am currently just using VS08.

Kirtan PatelRank #292 · 8.6K reputationPosted Oct 16, 2009, 7:00 AM EDT
to know all things about server CPU etc is not possible in asp.net using Query :)
but few things you can know using Query like its version etc
SELECT SERVERPROPERTY('productversion'), SERVERPROPERTY ('productlevel'), SERVERPROPERTY ('edition')
dobby30 reputationPosted Oct 16, 2009, 7:55 AM EDT
Kirtan PatelRank #292 · 8.6K reputationPosted Oct 16, 2009, 8:07 AM EDT
so its impossible by any technique :)
dobby30 reputationPosted Oct 16, 2009, 8:19 AM EDT
Kirtan PatelRank #292 · 8.6K reputationPosted Oct 16, 2009, 8:23 AM EDT
asp.net will allow you to write in C:\ only on your local computer but when you host your site it will not allow you to write in website user's c:\
because if it will allow you to do one can write a virus code and Execute on user's machine :P
thats potential security hole so asp.net ensures to write only on IIS Directory only :)
dobby30 reputationPosted Oct 16, 2009, 8:26 AM EDT
Kirtan PatelRank #292 · 8.6K reputationPosted Oct 16, 2009, 8:32 AM EDT
and Answer to your question about IDE
There are many IDE's in the Market not every person use VS
its depends uppon Which in language User prefer to Write Programs if user is writing program in C/C++ then it will use
IEther Dev C++ or code Blocks or Turbo C++ its not nesasory that to use Visual Studio :)
and friend , if my answer helped you please mark "do you like this answer" :)
Roei BarRank #1,271 · 1.4K reputationPosted Oct 16, 2009, 11:34 AM EDT
there is a way to enable access to the computer via IE which is via an ActiveX control
is this is approved via the user then he approves your actions.
another way is via SilverLight there is a location approved via the silverlight sandbox that enables your to do your approved via user actions on that sandbox area
Master BillaRank #2,229 · 630 reputationPosted Oct 16, 2009, 6:30 PM EDT
You can't use the WMI in asp.net application, the reason is when you asp.net
thank you
dobby30 reputationPosted Oct 20, 2009, 10:09 AM EDT