derma Close() menu?

I took a sniplet from mauritis.tv and added a close derma command as a test. Why doesn’t this work?



local HTMLTest = vgui.Create("HTML")
HTMLTest:SetPos(50,50)
HTMLTest:SetSize(ScrW() - 100, ScrH() - 100)
HTMLTest:OpenURL("http://www.garrysmod.com")
HTMLTest:Close()
-- timer.Simple(5, function() HTMLTest:Close() end)


Some examples from derma guides seem to give me errors. Is this because derma has been updated?

Use

[LUA]
HTMLTest:Remove()
[/LUA]

instead, that should work.

Thanks.

If you were using DFrames, then

[lua]
HTMLTest:Close()
[/lua]

would work just fine.