How to format USB & CD-Rome

Dani_S 4,501 Reputation points
2024-07-30T11:01:04.0133333+00:00

Hi,

I'm using net 8, I would like to format.

1.USB include bit locker.

2.CD-Rome

Can you supply full coe how to do it?

Thanks,

Windows development | Windows API - Win32
Developer technologies | .NET | Other
{count} vote

1 answer

Sort by: Most helpful
  1. Castorix31 90,686 Reputation points
    2024-09-16T19:01:48.2233333+00:00

    To format a CD-RW, you can use IMAPI2 and MsftDiscFormat2Erase

    There is an old but good sample at Code Project : https://www.codeproject.com/Articles/24544/Burning-and-Erasing-CD-DVD-Blu-ray-Media-with-C-an

    (Download source, main code is in backgroundFormatWorker_DoWork)

    I tested similar code in C#/Net 8 and the formatting worked with a DVD-RW drive and a CD-RW (I did not use events (for % of progression))


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.