This is wrong as CreateTypeLib() is supposed to create SLTG typelib. For https://bugs.winehq.org/show_bug.cgi?id=8780 preferred way is to fix vbscript/jscript so you don't have to switch to native. In any case you don't need separate QI call.