Loading and embedding fonts with code only. Doesn't work

I tried all day yesterday to find a solution to this… I’m generating some graphics which will be filled dynamically with text from an external xml. This text will be formatted with non-standard fonts, so I’ll have to embed the fonts.

I’ve found several blogs which talks about a method where you simply supply the path to the font and a name, which you then reference with a textformat object (format.font = “Name”).

I’m starting to doubt that this actually works in Flash CS3, and is only possible in Flex. Can anyone confirm this?

Example taken from one of the blogs:

[Embed(source='C:\WINDOWS\Fonts\FONT.ttf', fontName="Font", mimeType="application/x-font-truetype")]

mytextFormat.font = "Font";
// or
mytextField.htmlText = '<font face="Font">My text</font>';

A couple of blog links:
http://mx.coldstorageonline.com/?bid=48
http://www.marcosweskamp.com/blog/archives/000113.html