Solved

formating media

Posted on 2001-06-04
3
194 Views
Last Modified: 2006-11-17
Hi.
I need to format media (M.O. Disk or EOD) from my program.
I try the format utility, but it returns me "Can't read partition table". Where can I find any info about format failures and are there any other ways to format media?
Thank You in advance.
0
Comment
Question by:sisadmin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 2

Expert Comment

by:ToHo
ID: 6155331
Hi

If you are programming in VC there is a function called DeviceIoControl that can be used to format tracks on the disk. This will give extended failure information.
0
 
LVL 1

Author Comment

by:sisadmin
ID: 6155370
from DeviceIoControl reference:

dwIoControlCode
[in] Specifies the control code for the operation. This value identifies the specific operation to be performed and the type of device on which the operation is to be performed. No specific values are defined for the dwIoControlCode parameter. However, the writer of a custom device driver can define IOCTL_XXXX control codes, per the CTL_CODE macro. These control codes can then be advertised, and an application can use these control codes with DeviceIoControl to perform the driver-specific functions.

What is the IOCTL code for format and what is the format of parameter passing for this command?
0
 
LVL 2

Accepted Solution

by:
ToHo earned 100 total points
ID: 6155412
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question