Ticket #506 (closed enhancement: invalid)
Controls handling may causes problems
| Reported by: | carminaone | Owned by: | xue |
|---|---|---|---|
| Priority: | low | Milestone: | 3.1 Beta |
| Component: | Prado Framework v3 | Version: | 3.1 |
| Severity: | minor | Keywords: | |
| Cc: |
Description
Hi, i don't know if it's a bug or if i made something wrong; anyway : (details in my topic with the code)
I wanted to create a custom panel (with a header and a footer), so i created 3 panels (head, content, foot) in a TTemplateControl. I put a TPlaceHolder in the content one. when i use that template in a page, it copies all the Controls under it and adds them to the TPlaceHolder during the onInit.
This works fine until i want to use validators (they are not registered) as long as the validators are declared within this custom panel (just next to a TTextBox for example).
If i change my code so that the panel is created during the onPreRender(), the validators are then server-sided displayed, but i cannot, for example, EditCommand? in a TDataGrid within the panel anymore.
I guess something in the way Controls and Validators are handled is either missing or confusing.
Guess we could use a method to copy/paste or move the whole body content of a control, without alteration.
