on 06-20-2012 10:50 AM
Hi All,
I have XML string in one of attribute of view controller class, I need to display it in Web UI, how I can achieve it?
which is the HTMLB tag I need to use at .HTM of view...?
Thanks,
VjmHyd
Hi Nitish/Viswanath,
Here I am having one field which is getting populated from one of data base table,
this table have survey questions and answers in XML format.
So I need to display this field content in Web UI...
How I can do this?
Regards,
VjmHyd
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Nitish,
I need to display XML data which is having multiple lines...
above code is trying to displaying in same line, as well is data formating will it handle itself...
ex - XML data as below
<head><title> XYZ Survey</title></head><body style="font-family:verdana; background-color:#FFFFFF; color:#000000;"><table width="90%"><tr><td align="left" bgcolor="#FFFFFF"></td><td align="left" bgcolor="#FFFFFF"><p>This is a customer response from the xxx<br /><br />
Regards,
Vjmhyd
Hi Nitish,
Above tag will perfectly work fine for displaying text...
my question now is :
I am having text data in XML/HTML format and need to display it in Web UI, is it possible to get this displayed in proper output format
i.e. as we know if we try to store the XML code provided below in notepad and try to save as .HTM then try to execute the generated Web link then it will display in user readable format as below.
i.e.
<head> <title>XYZ Transactional Survey</title> </head> <body
style="font-family:verdana; background-color:#FFFFFF; color:#000000;">
<table width="90%"><tr><td align="left" bgcolor="#FFFFFF"></td> <td
align="left" bgcolor="#FFFFFF"><p>This is a customer response from the
XYZ Customer Experience Program.<br /><br />You are receiving this
response for information purposes. Please review the customer survey as
it holds valuable information on the customer's rating of
XYZ.</p></td></tr> <tr> <td align="left" valign="top"
bgcolor="#FFFFFF"></td> <td bgcolor="#FFFFFF"><table width="100%"> <tr>
<td valign="top">1. <b>This section is related to your general
experience with XYZ.</td> </tr> <tr> <td></td> </tr> </table></td>
</tr><tr> <td align="left" valign="top" bgcolor="#FFFFFF"></td> <td
bgcolor="#FFFFFF"><table width="100%"> <tr> <td valign="top">
above should get displayed as below :
This is a customer response from the XYZ Customer Experience Program. You are receiving this response for information purposes. Please review the customer survey as it holds valuable information on the customer's rating of XYZ. | |||
| |||
how to achieve above in Web UI...? which tags will help me...?
regards,
VjmHyd
Hi,
check out below code you can get to know
<%@page language="abap" %>
<%@extension name="chtmlb" prefix="chtmlb" %>
<%
DATA: lv_xml TYPE string,
lv_visible_row_count TYPE string.
lv_xml = controller->CONFIGURATION_DESCR->GET_CONFIG_DATA( ).
if ui->get_searchcollapsed( attribute_path = '' ) eq abap_false.
lv_visible_row_count = '10'.
else.
lv_visible_row_count = '20'.
endif.
data: lv_row_sel_event type string,
lr_cuco TYPE REF TO cl_bt108s_l_cucosearch_impl.
lr_cuco ?= controller->get_custom_controller( 'BT108S_LEA/CucoSearch' ).
IF lr_cuco->gv_process_mode EQ 'VALUEHELP'.
lv_row_sel_event = 'SINGLESELECTION'.
ELSE.
lv_row_sel_event = 'select'.
ENDIF.
%>
<chtmlb:configTable xml = "<%= lv_xml %>"
id = "ResultTable"
onRowSelection = "<%=lv_row_sel_event%>"
table = "//Result/Table"
width = "100%"
downloadToExcel = "<%= controller->gv_downloadtoexcel %>"
actions = "<%= controller->gt_button %>"
actionsMaxInRow = "6"
selectionMode = "<%=Result->selection_mode %>"
selectedRowIndex = "<%=Result->selected_index %>"
selectedRowIndexTable = "<%=Result->selection_tab %>"
usage = "SEARCHRESULT"
visibleRowCount = "<%=lv_visible_row_count %>"
reset = "<%= controller->gv_clear %>"
showNoMatchText = "FALSE"/>
otherwise goto BT108S_LEA check out the result view and resultac view....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
In web UI , where do you want to display- under any context nodes or as a separate input field ??
Regards,
Nithish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
5 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.