Atozed Forums
Create components at runtime - Printable Version

+- Atozed Forums (https://www.atozed.com/forums)
+-- Forum: Atozed Software Products (https://www.atozed.com/forums/forum-1.html)
+--- Forum: IntraWeb (https://www.atozed.com/forums/forum-3.html)
+---- Forum: English (https://www.atozed.com/forums/forum-16.html)
+----- Forum: IntraWeb General Discussion (https://www.atozed.com/forums/forum-4.html)
+----- Thread: Create components at runtime (/thread-4053.html)



Create components at runtime - ramiroflores - 04-23-2024

Hello,

I'm playing a bit with IntraWeb from Atozed software. I encountered a problem (maybe just my misunderstanding). For example, I can create a TIWLabel in the TIWForm.OnCreate event. Here it works the same as in Delphi, which is great. However, if I just want to create a TIWLabel when a button is pressed (AsyncClick event), the label is created but I can't force it to show.

Is there any way to do this? I just generate some text after the data is loaded from the database, and what is specifically loaded will be affected by the user. Pressing the button will then begin creating.

Thank!


RE: Create components at runtime - PaulWeem - 04-23-2024

Hi ramiroflores,

Have a look at the following demo:

https://github.com/Atozed/IntraWeb/tree/master/15/Delphi/AsyncRender

Hope this helps.

Cheers, Paul


RE: Create components at runtime - Alexandre Machado - 04-29-2024

Hi Ramiro,

Paul gave you the correct link to one of our demos that show this feature.

You didn't show any code, but the key here is to correctly set the parent of the IWLabel, the name and position.