Find position of SelectionGrid element clicked

How do you find the screenspace position of a SelectionGrid element that is clicked?

It’s pretty simple. You just feed the int you get back from the function into the string array you give to the function, like this:

var selGridInt : int = 0;
var selStrings : String[] = ["Grid 1", "Grid 2", "Grid 3", "Grid 4"];
    
    function OnGUI()
    {
       selGridInt = GUI.SelectionGrid (Rect (25, 25, 100, 100), selGridInt, selStrings, 2);
	   Debug.Log(selStrings[selGridInt]);
    }

If you have a list of eg. buttons inside your grid, I would take the selection-value from the Grid and multiply it with the pixelheight of the button-style. This might be 25 pixels or something.

Would that work or are your content of different heights?