What's up with PtcCrt's delay procedure? lazarus / 21-General ---------------------------------------------------------------------- TBMan · 2025-02-02 18:48 It just acts wonky at times. I've resorted to using a longint as a timer for certain things. ---------------------------------------------------------------------- TRon · 2025-02-03 20:02 tbh I never use delay so can't say I am familiar with the issue. I use sleep and timers when working with PTC. Could you share a reproducible example ? ---------------------------------------------------------------------- Thaddy · 2025-02-04 07:58 The description you gave is not very helpful. I am missing a compilable example, platform, bitness. ptc has many lowlevel implementations and these differ per platform, e.g. on Win and Lin the behavior is different in some cases. ---------------------------------------------------------------------- Thaddy · 2025-02-04 08:31 Also note that on most platforms delays should not be used as precision timers: they just guarantee a minimum delay() but otherwise have no priority. You need OS timers for that. ---------------------------------------------------------------------- TBMan · 2025-02-09 21:07 It just seems to be inconsistent in its use. Maybe it's my system. Sometimes 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 Delay(10) takes forever and it shouldn't. It's probably my usage of it (in loops at times). Thanks for the responses.