on 05-16-2005 6:50 PM
Hello Experts-
I am trying to creating a context attribute of the type 'Visibility'.
How do I do this?
In the drop-down list for the types that I can pick, I do not see one called Visibility.
Do I have to reference that type to the class 'com.sap.tc.webdynpro.progmodel.api.WDVisibility
' by putting this classname into the type field?
Thank you,
- Vik.
Hi
You can only select the type Visibility when you are in the Context of a View. It won't work in the context of a Controller.
Select "Dictionary Simple Type" then:
Dictionaries --> Local Dictionary --> com.sap.ide.webdynpro.uielementdefinitions --> Visibility
Jeschael
ps. I know this question is old, but I could not find this answer on SDN. I have been searching for it for a day. Maybe it is of use to someone.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi
create a value attribute . then select the property type of the value attribute, select browse and select dictionary simple type.
under the dictionary a list of packages will be displayed from that select the package com.sap.ide.webdynpro.uielementdefinitions
from that select the element visibility.
now you can set the visibility through this attribute.
hope this works.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vik,
I guess you used the wrong class of Visibility.
The correct class should be com.sap.ide.webdynpro.uielementdefinitions.Visibility
but not com.sap.tc.webdynpro.progmodel.api.WDVisibility
I guess you have already solved the problem.
Cheers
Message was edited by: Jack Xiong
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
1. Create a value attribute (eg. vaVisibility)
2. For "type" property, click on the "..." button.
3. Select the "Java Native Type"
4. Click on the "Browse" button
5. Enter "WDVisibility" select the "com.sap.tc.webdynpro.progmodel.api.WDVisibility"
Hope this helps you.
Regards,
Santhosh.C
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Naga and Santhosh-
I tried both your techniques but am facing many errors in Eclipse. Whether I assign the 'Visibility' type to my value attribute via 'Java Native' route or 'Dictionary Simple', I am getting many errors. The errors I am getting are exactly the same regardless of which these two methods I use.
I am copying the descriptions of the errors that I am getting in Eclipse below this message.
Thank you,
- Vik.
com.sap.tc.webdynpro.progmodel.api.WDVisibility cannot be resolved (or is not a valid type) for the field IContextElement._vaVisibility
com.sap.tc.webdynpro.progmodel.api.WDVisibility cannot be resolved (or is not a valid return type) for the method getVaVisibility
_vaVisibility cannot be resolved
com.sap.tc.webdynpro.progmodel.api.WDVisibility cannot be resolved (or is not a valid type) for the argument value of the method setVaVisibility
_vaVisibility cannot be resolved or is not a field
_vaVisibility cannot be resolved
_vaVisibility cannot be resolved or is not a field
com.sap.tc.webdynpro.progmodel.api.WDVisibility cannot be resolved or is not a type
Hi Vik,
It looks more like a classpath issue. Did you get the following jar file set in the classpath of your project NDS.
C:\Program Files\SAP\JDT\eclipse\plugins\com.sap.tc.webdynpro.runtime\lib\_webdynpro_progmodel.jar
Check the project properties --> Java Build Path --> Libraries and see whether the above jar is included or not. If the above jar is not included then try to add the jar from the above path and try to build the component again.
Regards,
Santhosh.C
Hello Santhosh-
I checked the '_webdynpro_progmodel.jar' file and it is in the classpath of the project.
When I go the 'Dictionary Simple' route, I find the 'Visibility' type in local dictionary. As soon as I assign it to my value attribute and switch into the implementation view is when all the Eclipse errors pop-up. (BTW, going this route Eclipse finds the WDVisibility class in the package 'com.sap.ide.webdynpro.uielementdefinitions')
When I go the the 'Java Native' route and search for WDVisibility, the type shows up (as class) and I can select it as the type for this value attribute. Again, its after I switch into the implementation view is when all the Eclipse errors pop-up. (BTW, going this route Eclipse finds the WDVisibility class in the package 'com.sap.tc.webdynpro.progmodel.api')
Is there anything else you can recommend?
Thank you,
- Vik.
Hello Santhosh-
I tried to 'Organize Imports' but this did not help.
I am developing the application on JDT 2.0.9 and that is where I am facing these problems with wdVisibility as a context attribute type.
I pulled my project into JDT 2.0.11 and created a context attribute of the type visibility and there I did not encounter any such errors.
Thanks for your time,
- Vik.
Hi Vik
You can get the visibility properties in UI definitons.
Click on the properties of the attribute. Choose Dictionary simple type and Expand local dictionary.
You can see comp.sap.ide.webdynpro.uielement definitions.
expand this and you can find the option visibility.
select and click Ok.
Kishore
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.