The following function is intended to make a large grid (58 X 31) of characters that are individual links that will perform a function based on the x,y coordinates of the clicked character. The function prints the grid correctly but the link actions have the wrong coordinates. If I put a print statement in the function, it prints the expected x and y (q and k) values.
- As long as the input table is the same, the incorrect values are always the same (i.e. the top left N is always 51,26 for table "zonename").
- The links are a repeating pattern. Exactly every 500 grid spots, the pattern begins again with 51,26.
- X values correctly range between 1-58. Y values range between 23-31.
- The last 487 links are correct.