Simplica

ProductsLearnPurchaseSupportDemoDownload
  [Search] Search   [Recent Topics] Recent Topics  
how to dynamic create UIComponent on cell onstartedit event?
Forum Index -> DataTable
Author Message
firebow1


Joined: 05/17/2007 00:00:00
Messages: 8
Offline

hi all:
i want to dynamic create UIComponent on cell onstartedit event in gridtable.there is different edit mode on every row.
etc:
on row one create a select component
on row two create a textbox
on row three create a radio
my code:

the view is not change.
why?
thanks a lot
adina_mihai
Simplica Team

Joined: 04/01/2007 00:00:00
Messages: 189
Offline

onstarteditcell is fired after cell enters in edit mode so your method won't work.

GridCell was designed to use same edit control for all rows for a column But to specify different edit controls for each row you can try two aproaches:

- use a different datarow for each row type. In this case if you define three datarows and a datamodel with 2 rows gridtable will render 6 rows on the client.

- use facet GridTable.EDIT_FACET_NAME to specify custom edit controls in grid cell like this :




Basically you put different controls that will render only if a condition is true for a particular row.
firebow1


Joined: 05/17/2007 00:00:00
Messages: 8
Offline

thanks a lot!
but my select and selectItem is dynamic .they stored in database.
i am despair.
this function will add in your next version?
and the charset problem.
adina_mihai
Simplica Team

Joined: 04/01/2007 00:00:00
Messages: 189
Offline

Yes, we will add these features in our next release.
Thanks for your interest.
 
Forum Index -> DataTable
Go to:   
Powered by JForum 2.1.7 © JForum Team
Home   |  News   |  Contact   |  About   |  License   |  Privacy   |  Documentation
Copyright © 2009 Simplica Corporation. All rights reserved.