on 05-16-2008 6:48 AM
Hi All,
I want to display an image as the background for the table cell.
I searched in sdn and found the solution only for link to action.
I have created a dynamic table and if i click on apply button one more row is getting added according to my requirement.
I want to differentiate this row from rest. So I need to display image for the last row in the table which is added newly.
Can anyone suggest the procedure for adding an image in a particular cell editor along with the table data?
Hope I am clear with my requirement.
Pls suggest.
Regards,
subashini
Kindly close the thread if ur issue is resolved.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
IF iam not wrong then for some rows u need to show text data and for some rows u need to show image data.
follow the following steps.
1. In ur table add cell editor of type Image.
2.Create a value node with one more than required attributes.
3.Suppose if need to show only one column then i will create
value node with two attributes.One attribute will be for text
data and one will for Image.
4.now access ur table cell editor dynamically.For image type
cell editor we need to play only with two properties source
and alt.Bind this alt property of editor wid that attribute which u
need use for text data and source wid that attribute which u
need to use for image.
5. Now suppose I need to show text data then
I will create one element of that value node.In case of Image
type cell editor source property is given prefrence over alt
property.
set attribute which is bound to alt to the actual text data
i.e setText("Actual text data");
and set attribute which is bound to source to some dummy
image name
i.e setImage("dummy.gif");
add this to node.
during execution as source property of editor is bound to
Image attribute of node which in turn is set to dummy value it
wont find actual source and will set Image cell editor with
watever is bound to alt property which in turn set with actual
text value..
6. Now suppose I need to show Image data then
I will create one element of that value node.In case of Image
type cell editor source property is given prefrence over alt
property.
set attribute which is bound to alt to blank value
i.e setText("");
and set attribute which is bound to source to some Actual
image name
i.e setImage("Image.gif");
add this to node.
during execution as source property of editor is bound to
Image attribute of node which in turn is set to Actual image file
it will set Image cell editor with that image name and wont look for alt property.
Copy all ur images in src->mimes->components->ur package
Regards
Surender Dahiya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.