Sample

LuaCOM

next up previous contents Next: isMember Up: GetIUnknown Previous: Return Values   Contents

Sample

-- Creates two LuaCOM objects for the same COM object
-- (a running instance of Microsoft Word(R)  )
word1 = luacom.GetObject("Word.Application")
word2 = luacom.GetObject("Word.Application")
-- These two userdata should be the same
unk1 = luacom.GetIUnknown(word1)
unk2 = luacom.GetIUnknown(word2)
assert(unk1 == unk2)



Fabio Mascarenhas de Queiroz 2005-01-07