Finalizing a disc

I have been writing an application which requires the use of a CD burner to burn reports to a CD. I am using the Window’s IMAPI interface, which is nice, because it makes some things easy for you, but at the same time, presents some maddening limitations.

One of these is the fact that you cannot finalize a CD using IMAPI. This is not normally a problem, except that we do not want anyone writing to these CDs once they have the reports on them.

I read somewhere that finalizing a CD is done by not writing a pointer to where the next table of contents would be written during the next session. The IMAPI engine automatically writes this pointer, so I was thinking that I could get around this limitation by writing a session without any files using a different, lower level API, and then not writing the pointer to the next section.

First off, what do you think? Will this strategy work? And if it will, can someone point me to information on how to do this, or a piece of source code that does this already?

Thankyou for your time