cancel
Showing results for 
Search instead for 
Did you mean: 

regarding Link to URL UI Element in a table

jnmurthi
Participant
0 Kudos

Hi All,

I am using "link to url" UI Element in a table column. I have mapped the column (i mean the "reference" property of "link to url" UI to a bapi node). Now, when I am populating the table, for some rows the bapi is not returning the url links. So, the column is getting disabled and not even showing the links for the rows which are getting the url link from the bapi.

Is there any way to set the mapping row wise, so that the rows which have data get enabled with the link and which do not have data will be disabled.

Also, can I make the whole table readonly, except for one column.

Please help me in this regard.

Regards,

Murthy.

Accepted Solutions (1)

Accepted Solutions (1)

abhimanyu_lagishetti7
Active Contributor
0 Kudos

Hi

If the reference is null the link will be disabled.

Even if you want some ofthe links enabled and some are disabled you can use the Enable Property of the control.

But if you use Model Node directly you can not add new attributes to the node

So Create similar Value node by Structure Binding and bind it to your table control.

create a new Attribute(enable) in the Node which is binded to your table control of type boolean.

bind it to the control.

and just loop at the value node elements and set the attribute(enabled) true or false accordingly.

Regards

Abhimanyu L

jnmurthi
Participant
0 Kudos

Hi Abhimanyu,

I have tried that, but still it is disabled. This is because, the node is mapped to the column of the table and also the enabled(attribute) is also mapped to the column.

Is there any way to assign properties row wise, so that one row doesn't effect another.

Also, is there any way to make a table readonly, except for one column.

Regards,

Murthy.

Former Member
0 Kudos

Please post your context structure and how you have bound the LinkToURL.

Armin

jnmurthi
Participant
0 Kudos

HI,

Bapi Node

---OutputNode

-


DataNode

-


url attribute

I took this into local node

context

-


url attribute

I am binding this "url attribute" to the "reference" property of the link to url UI which is used as a TableCellEditor in my table.

Regards,

Murthy.

Former Member
0 Kudos

The attribute providing the URL for the links must be located under the node used as data source for the table. Otherwise all table rows will have the same value.

Armin

jnmurthi
Participant
0 Kudos

Hi Armin,

Thank you very much. The problem is solved. 10 points for you.

Another Question.......

Can we make the table readonly, leaving just one column to select.(that is the column with link to url). Is it possible? If so, please tell me how....

Also, can you tell me the reason for the following exception.....

<b>com.sap.tc.webdynpro.progmodel.context.ContextConfigurationException: DataNodeInfo(CreateTemplateComp.Zad_Bapi_Get_Template_Details_Input.Output.T_Template_Details): structure field Ad_Height not found

at com.sap.tc.webdynpro.progmodel.context.DataAttributeInfo.init(DataAttributeInfo.java:299)

at com.sap.tc.webdynpro.progmodel.context.NodeInfo.initUnmappedAttributes(NodeInfo.java:687)

at com.sap.tc.webdynpro.progmodel.context.DataNodeInfo.doInit(DataNodeInfo.java:238)

at com.sap.tc.webdynpro.progmodel.context.NodeInfo.init(NodeInfo.java:671)

at com.sap.tc.webdynpro.progmodel.context.NodeInfo.init(NodeInfo.java:674)

... 49 more</b>

Former Member
0 Kudos

Please open a new thread for the last question.

To answer the first: Yes, you can do this. Just disable or set read-only all the table cell editors of the other columns.

Armin

jnmurthi
Participant
0 Kudos

Hi Armin,

I am using Textviews as table cell editors. I am not getting any option like "readonly" property in the properties window.

How can I do this?

Regards,

Murthy.

Former Member
0 Kudos

TextViews are always read-only.

Armin

Answers (0)