Referring to a GUI element in another form lazarus / 31-LCL ---------------------------------------------------------------------- segfault · 2017-12-02 10:58 I have a program with 2 forms. When attempting to get the status of a checkbox in the sub-form by referring to it in the main form, I'm getting an 'identifier not found' error, even though I have added the sub-form's unit to the 'uses' list. Any idea what I'm missing? Thanks. ---------------------------------------------------------------------- KemBill · 2017-12-02 11:15 Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i form2.checkbox1 assuming the form name is form2 and checkbox1 is the check box name ---------------------------------------------------------------------- segfault · 2017-12-02 11:39 Thanks! ---------------------------------------------------------------------- Graeme · 2017-12-10 09:34 On a side note:   Using good OOP practise, I recommend you define a Public property on "form2" that checks and returns the value of the UI component. Never hard-code component names like than into you application/business logic. Just my 2c.