It's not possible to open the player inventory GUI because it's entirely client side. However you can copy the contents into a chest inventory and open that.