Help: Possible to make a Defragger?
If you need help with a project or need to know how to do something specific in VB.NET then please ask your questions in here.
Forum rules
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
Please LOCK your topics once you have found the solution to your question so we know you no longer require help with your query.
4 posts
Page 1 of 1
Hey, guys. I'm needing of help on making a defragger without help from anti-viruses. I know that there is a system defragger on all computers but don't know how and also the codes. Can you help me? idoit;
i dont defrag i was able find this
this could help you some times http://msdn.microsoft.com/en-us/library ... 85%29.aspx
Code: Select all
dont forget to add system.management Dim ComputerName As String = ""
Dim wmi As New ManagementObjectSearcher("Select * from Win32_Volume Where Name = 'C:\\'")
Dim volumes As ManagementObjectCollection
volumes = wmi.Get()
For Each Volume As ManagementObject In volumes
Volume.InvokeMethod("Defrag", Nothing)
Next
this could help you some times http://msdn.microsoft.com/en-us/library ... 85%29.aspx

Find my programs on Softpedia
Hello, #mshimranpro. Sorry, I couldn't find System.Management.dll. I know it's in Reference in my Projects Properties but I wouldn't add.
This might be a possible solution:
"The problem happens because System.Management.dll is not referenced by VB.NET compiler by default. In contrast, C# compiler references to this DLL by default in your csc.rsp file. The simpliest way to resolve the issue is to add the following content in the web.config file of your web application, or if you don't have this file, add one with the content below. -- Andy Cheung Microsoft WMI Test Engineer This posting is provided "As Is" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at http://www.microsoft.com/info/cpyright.htm"
Source: http://forums.asp.net/t/46697.aspx
"The problem happens because System.Management.dll is not referenced by VB.NET compiler by default. In contrast, C# compiler references to this DLL by default in your csc.rsp file. The simpliest way to resolve the issue is to add the following content in the web.config file of your web application, or if you don't have this file, add one with the content below. -- Andy Cheung Microsoft WMI Test Engineer This posting is provided "As Is" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at http://www.microsoft.com/info/cpyright.htm"
Source: http://forums.asp.net/t/46697.aspx
My name is Tom | Visit my blog where I post new content every day! Tom's Daily Blog | MineCraft is awesome!
4 posts
Page 1 of 1
Copyright Information
Copyright © Codenstuff.com 2020 - 2023