![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
#3
| |||
| |||
|
|
Hi Trapulo, There's no official documentation on how to use defrag api from .NET, but there's some example code: #Jeffrey Wall's WebLog : Defrag API C# wrappers http://blogs.msdn.com/jeffrey_wall/a...13/229137.aspx Hope this helps. Regards, Walter Wang (wawang (AT) online (DOT) microsoft.com, remove 'online.') Microsoft Online Community Support ================================================== When responding to posts, please "Reply to Group" via your newsreader so that others may learn and benefit from your issue. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights. |
#4
| |||
| |||
|
|
Thank you, this is a starting point. Is there the official documentation about defrag api? I cannot find it. thanks ""Walter Wang [MSFT]"" <wawang (AT) online (DOT) microsoft.com> wrote in message news:YMjCFXjMIHA.5204 (AT) TK2MSFTNGHUB02 (DOT) phx.gbl... Hi Trapulo, There's no official documentation on how to use defrag api from .NET, but there's some example code: #Jeffrey Wall's WebLog : Defrag API C# wrappers http://blogs.msdn.com/jeffrey_wall/a...13/229137.aspx Hope this helps. Regards, Walter Wang (wawang (AT) online (DOT) microsoft.com, remove 'online.') Microsoft Online Community Support ================================================== When responding to posts, please "Reply to Group" via your newsreader so that others may learn and benefit from your issue. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights. |
#5
| |||
| |||
|
#6
| |||
| |||
|
|
Thanks Willy for your input. Hi Trapulo, Would you please let us know what's your requirement here? You may find following information helpful to understand how defragment works: #Inside Windows NT Disk Defragmenting http://www.microsoft.com/technet/sys...kDefragmenting. mspx To add to Willy's suggestion about defragment using WMI, please refer to following document: #Defragmenting Disks the Windows 2003 Way http://www.microsoft.com/technet/scr...03/defrag.mspx Hope this helps. Regards, Walter Wang (wawang (AT) online (DOT) microsoft.com, remove 'online.') Microsoft Online Community Support ================================================== When responding to posts, please "Reply to Group" via your newsreader so that others may learn and benefit from your issue. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights. |
#7
| |||
| |||
|
#8
| |||
| |||
|
|
Hi Trapulo, We currently don't have much public documentation on the low level defragment APIs, I suggest you to contact our Advisory Service for more support on this. |
|
By the way, if your objective here is to make a single file continuous, you might find contig.exe useful: #Contig v1.54 http://www.microsoft.com/technet/sys...sk/Contig.mspx quote Contig is a single-file defragmenter that attempts to make files contiguous on disk. Its perfect for quickly optimizing files that are continuously becoming fragmented, or that you want to ensure are in as few fragments as possible. /quote |

![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |