User has inserted pixel dimensions (yes this is version 2.0 completely re-vamped due to extensive growth in wisdom)

Please no answers...a winsy clue just to annoy me further would be nice...thankyou
All tabs are on one card
All this code is in the group "printpapersize" which is nested within the larger group that holds the text entry field and the result field at the bottom of the card.
global gPixels, gSize
on mouseUp
put fld "pixelLongestSide" into gPixels
put of grp "printPaperSize" into gSize
if gSize = button "A2" then
put trunc (gPixels / 23.4) into fld "ppiResult"
end if
if gSize = button "A3+" then
put trunc (gPixels / 19.1) into fld "ppiResult"
end if
if gSize = button "A3" then
put trunc (gPixels / 16.5) into fld "ppiResult"
end if
if gSize = button "A4" then
put trunc (gPixels / 11.7) into fld "ppiResult"
end if
if gSize = button "A5" then
put trunc (gPixels / 8.3) into fld "ppiResult"
end if
if gSize = button "A6" then
put trunc (gPixels / 5.

end if
end mouseUp