cancel
Showing results for 
Search instead for 
Did you mean: 

How to use CL_GUI_HTML_VIEWER in ITS mobile's cust_control

Former Member
0 Kudos

Dear Experts,

as ITS mobile defines a list of supported controls, we know that CL_GUI_HTML_VIEWER in a cust_control is NOT part of this list.

But nevertheless, we try to understand & adopt the scripts in internet service ITSMOBILE/99/CUST_CONTROLS

`function cust_control(name, width, height)

  if (^name.type == "gridview")

    include(~service="itsmobile", ~theme="99", ~name="alv_grid.html");

    alv_grid(name, width, height);

  elsif (^name.type == "image")

    include(~service="itsmobile", ~theme="99", ~name="image.html");

    image(name, width, height);

  else

    `<``!-- unsupported custom control --``>`

  end;

end;`

We got that the ^name.type is "htmlview". So we run to the else branch with "unsupported custom control"

Now we like to place code here to extract the HTML code generated by the CL_GUI_HTML_VIEWER (may be out of the name variable) and put it into HTML output stream so that the contedt of the control is displayed.

The WebGUI for HTML does the same somehow in the internet service SYSTEM/DM/TEMPLATELIBRARYDYNPRO

But we are not HTMLB experts and it is hard to understand how ...

- the name variable is structured

- the syntax to mix HTMLB / JavaScript / HTML

Any ideas to get new input in that topics ?

Thanks in advance & best regards,

  Matthias

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member184158
Active Contributor
0 Kudos

I have the same problem

I can not run ALV Grid in ITS

any suggest

INCLUDE/CUST_CONTROLS

`

<!-- declare alv_grid(name, width, height) in "some.html"; -->

`<span>test:`var_content_service`, `var_content_theme`</span>`

function cust_control(name, width, height)

    `<span>test:`var_content_service`, `var_content_theme`</span>`

end;`

`include(~service="itsmobile", ~theme="99", ~name="alv_grid.html");

alv_grid("D3741_CC_SD_AF_LISTE", 16, 14);`