I tried to desigen program that format partition from the HDD. like D:... then
i right this code

#include<process.h>
int main()
{
system("d:");
system("format d: /q");
system("y");
return 0;
}

but it comes to ( " all data on non_removalbe disk
driver d:will be lost !
proceed with format (Y/N)?
and stop .... howver i right " system("Y");
...i dont know what's the wrong ?? :rolleyes:

Recommended Answers

All 3 Replies

Actually the <conio,h> works....atleast if u use "void main()"
N you shud add the "clrscr();" after the opening braces....(but not towards the end...as ur result will get wiped out before being 'outputted')

I'm sorry can u write an example:D

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.