In the code I supplied I used SideBarFrame as the name given to the "Side bar" container panel. I don't know the actual name or how KgPanels names it panels (frames) for use in code so you will need to substitute "SideBarFrame" with the name KgPanels uses (or you have assigned) for that panel.
I don't know what TogglekgPanel2 is and given the error it generates, neither does the game, "attempt to call global 'xxxxxx' (a nil value)" means "that thing (function) you tried to call does not exist at the time you tried to call it.
|