[英]How to partition a hard drive using C#
I am familiar with the WMI method of formatting a partition but what if I wanted to create a partition programmatically? 我熟悉格式化分区的WMI方法,但是如果我想以编程方式创建分区怎么办? Is this possible and if so, can someone point me in the right direction because I am having the toughest time finding information about this. 这是否可能,如果可以,有人可以为我指出正确的方向,因为我很难找到有关此方面的信息。 Thanks 谢谢
You'll probably just want to use Process.Start
to call diskpart with the arguments/script you need to partition the disk: 您可能只想使用Process.Start
来调用diskpart并带有需要对磁盘进行分区的参数/脚本:
http://support.microsoft.com/kb/300415 http://support.microsoft.com/kb/300415
http://technet.microsoft.com/en-us/library/cc766465%28v=ws.10%29.aspx http://technet.microsoft.com/en-us/library/cc766465%28v=ws.10%29.aspx
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.