There exist 6 implementations of GUI.SelectionGrid, 2 of which match the 4 parameters in your call:
static function SelectionGrid (position : Rect, selected : int, images : Texture[], xCount : int) : int
static function SelectionGrid (position : Rect, selected : int, content : GUIContent[], xCount : int) : int
texButConWom is an array of type Object: both Texture and GUIContent inherit from Object, so the compiler doesn’t know which function call to choose. You need to explicitly define texButConWom as either a Texture[ ] or a GUIContent[ ], so the compiler knows which implementation of GUI.SelectionGrid to pick.
I spent several hours researching this (documentation and forum) and attempting code without success. The documentation confirms what you wrote and my understanding is in line with this.
However:
“You need to explicitly define texButConWom as either a Texture[ ] or a GUIContent[ ], so the compiler knows which implementation of GUI.SelectionGrid to pick.”
This is where I am stuck. My numerous attempts to ‘explicitly define texButConWom’ have been unsuccessful and this is why I wrote to the forum.
I propose that someone try Resources.LoadAll with SelectionGrid and see if they can get this to work.
I would be happy to see any code where the two work together.
This function is VERY important to me because I need the ability to easily change large numbers of files just by dropping them into a folder. Doing this through the inspector is HIGHLY tedious and time consuming.