ComponentOne Word for WinForms
Working with Word for WinForms / Advanced Level Working / Playing Metafiles
In This Topic
    Playing Metafiles
    In This Topic

    A Metafile is a type of file that can store variety of data. You can add .emf and .wmf images to your word documents. Following code shows the use of DrawMetafile method to draw a metafile image in a Word document:

    Dim img As Image = Metafile.FromFile(dlg.FileName)
    C1Word.DrawMetafile(DirectCast(img, Metafile))
    
    Image img = Metafile.FromFile(dlg.FileName);
    C1Word.DrawMetafile((Metafile)img);