Use a reference to The Form as a Procedure Parameter lazarus / 21-General ---------------------------------------------------------------------- Weitentaaal · 2021-01-25 08:51 Hello just a Short Question: is it possible to do this?:  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  Function TGlobals.Calc_STD(var curForm: Form; FeldD: String; ResEurevo: Single): Boolean;   and in my Function then do something like 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  curForm.Name Thanks ---------------------------------------------------------------------- MarkMLl · 2021-01-25 09:22 Should be but the type is TForm and don't pass it as var... you aren't going to change it, and an object is implicitly passed by address/reference. MarkMLl ---------------------------------------------------------------------- dbannon · 2021-01-25 09:36 Not sure exactly what you are asking here Weitentaaal.  Let me try .. You want to set a variable to point to a form and do things like call methods in the form from that variable ?  Yeah, no problems.  For example, I have a unit/form called TEditBoxForm.  I make any number of these forms, each one displays a note from a note collection. 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 procedure ShowNote(anEBox : TEditBoxForm);begin    anEBox.show;end; var    EBox : TEditBoxForm;    NoteFileName : string;    TheForm : TForm;begin     EBox := TEditBoxForm.Create(Application);    EBox.NoteTitle:= NoteTitle;    EBox.NoteFileName := NoteFileName;     ShowNote(EBox);      .... I might then, save the value of EBox in a list so I can later look through all the open notes, see if user has closed one etc.  I am using, as an example here, a form I create rather than have it created at startup because for what you are asking seems to make more sense with dynamically created forms. Is this the sort of thing you are after ? Davo ---------------------------------------------------------------------- Weitentaaal · 2021-01-25 09:41 Yesss Was looking For this Thank u Guys