on 02-08-2006 4:09 PM
Hi,
I was trying to find a help about "How to disable/enable property of an image in Web Dynpro?" but never find it. Let me explain what I'm trying to do:
I need to show three different status (Released, Rejected and Approved) each one is an image ... <b>How do I do to disable images property before a process and enable them after it?</b>
Thanks in Advance, and waiting an answer As Soon As Possible !!!
Tokio
Your question is not completely clear to me. An image cannot trigger an event, so disabling it has no effect.
To display different images in a Image element depending on some condition, you can use a calculated context attribute <i>imageSource </i>of type "string" that returns the URL of the image, something like
public String getImageSource(IWDNodeElement element)
{
if (...)
{
return "image_for_status1";
}
else if (...)
{
return "image_for_status2";
}
else if (...)
{
return "image_for_status3";
}
return ""; /* no image will appear */
}
Bind property Image.<i>source </i>to attribute <i>imageSource</i>.
If you put the three image files inside folder src/mimes/components/<componentName>, your method can simply return the file name without calculating an URL.
Armin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do you mean Visibility?
If yes, you can create in the context a value attribute of type visibility and change the visibility to NONE/VISIBLE according to your program's needs.
To create a value attribute of type visibility:
1) Create a new value attribute
2) Go to the "type" property and click "..."
3) Select "com.sap.ide.webdynpro.uielementdefinitions"
4) Select "Visibility"
Omri
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.