rayp, 3run's code will work 100% but it doesnt include the functions to actualy open/close the inventory, wich are inv_open_bag() and inv_close_bag(), so he might feel too lazy to modify his existing code and add those to 3run's example...
Ruben, I think the problem is in this one:
diag("\nWARNING: inv_close_bag called with argument NULL\n");
Use -diag option to see if this message shows in the acknex log file.
First , you should'nt use "bag" pointer when you're creating a bag.
Use something like "bag01" or "bag_01". You can never be shure it is'nt used somewhere else for something else.
Second, check how you created the bag. Check for small erors in sintax...
Your inventory showing means that the panel is created, but not going away means it isnt destroyed when you close the inventory, from what I see in the file.