cancel
Showing results for 
Search instead for 
Did you mean: 

Table control on ITS need to design

Former Member
0 Kudos

Hi,

Can anybody let me know how to create Table Control on ITS Template ?

I need to create one Table control in ITS template in internet service .

With this i also need to transfer OK code in SAPGUI .

I have created Table contol in SAP gui and want to display on ITS Template .

I have internal table which i want to show on ITS .

any help will be appreciated .

Thanks,

SS

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

ITS template for table control looks like that:

On the top of the page you load main services like wpintegration.html or any JavaScript files.

I have table control with name TC_PERSONAREA and sctucture GS_PERSONAREA.

You must add a loop statement for all values in table.


<!-- Start: Responsible persons (template 9000) -->
<html>
<head>
`include (~service="bbpglobal", ~name="WpIntegration.html" )`
<script language="JavaScript" src="`mimeURL(~service="bbpglobal", ~language="", ~name="script/bbpscript.js")`">
</script>
`include (~service="bbpglobal", ~name="bbpfunctions.html")` 
<title>`~windowtitle`</title>
  `Stylesheet()`
  `ApplicationTitle()`

`BBPGroupBegin()`
  `emptyLinesGroup = 0`

<!--`TABLE(class="list", title=TC_PERSONAREA.title)` -->

  `TABLE(class="list", title=#PERSONAREA)`
    `TR(tableName=TC_PERSONAREA.title)`
    `if(GS_PERSONLIST-BNAME.dim == 0)`
      `TR()`
        `TD(active="")``#EMPTY_PERSON_AREA_9000`
    `else`
      `TR(class="heading")`
        `TD(content=#PERSONAREA_ASSIGN)`
        `TD(content=TC_PERSONAREA-column[1].title)`
        `TD(content=TC_PERSONAREA-column[2].title)`
	
      `repeat with j from TC_PERSONAREA.firstvisible to TC_PERSONAREA.lastvisible`
        `if(GS_PERSONLIST-BNAME[j].value != "")`

          `TR()`

            `TD(align="center")`
              <input type="hidden"   name="TC_PERSONAREA-rowselect[`j`]" VALUE=" ">
              <!-- <input type="checkbox" name="TC_PERSONAREA-rowselect[`j`]" value="x" `if(TC_PERSONAREA-rowselect[j].selected)` checked `end`> -->
		 <input type="radio" name="TC_PERSONAREA-rowselect" value="`j`" `if(TC_PERSONAREA-rowselect[j].selected)` checked `end`>
              `if (GS_PERSONLIST-BNAME[j].value != "")`
                 `tooltip = GS_PERSONLIST-BNAME[j].value`
              `else`
                 `tooltip = ""`
              `end`                          

              `if (GS_PERSONLIST-BNAME[j].value != "" && GS_PERSONLIST-BNAME[j].value != "")`
                `TD(title=tooltip)`
			 `GS_PERSONLIST-BNAME[j].value`
              `else`
                `TD(title=tooltip, active="")`
			`GS_PERSONLIST-BNAME[j].value`
              `end`

            `TD(active="")` `GS_PERSONLIST-F_NAME[j].value` 

        `else`
           `emptyLinesGroup = emptyLinesGroup + 1`
        `end`
      `end`      
    `end`

  `endTABLE()`

  `BBPVSpace()`

  <table cellspacing="0" cellpadding="0" border="0" width="100%">
    <tr>
      <td tabindex="0" align="left" nowrap>
        `if(GS_PERSONLIST-BNAME.dim == 0)`
          `BBPButtonBegin()`
          `BBPDisabledButton(RESP_PER_SAVE_BUTTON.label)`
	`BBPButtonSpace()`
	`BBPDisabledButton(RESP_PER_BACK_BUTTON.label)`
	`BBPButtonEnd()`
	`BBPVSpace()`
        `else`
          `BBPButtonBegin()`
          `BBPButton(RESP_PER_SAVE_BUTTON.okcode,RESP_PER_SAVE_BUTTON.label)`
	`BBPButtonSpace()`
	`BBPButton(RESP_PER_BACK_BUTTON.okcode,RESP_PER_BACK_BUTTON.label)`
	`BBPButtonEnd()`
        `end`
      </td>
      `if((TC_PERSONAREA.firstvisible > 1 ) || (TC_PERSONAREA.lastvisible < TC_PERSONAREA.rowcount))`
        <td  tabindex="0" align="right" valign="middle">
          `BBPTCNavigation("TC_PERSONAREA", emptyLinesGroup)`
        </td>
      `end`
    </tr>
  </table>

`BBPGroupEnd()`

Regards,

Marcin

Former Member
0 Kudos

Hi,

Here i am getting only rows which can be display without scrolling .

Actually there are 25 rows but initially can see only five rest of these can be seen

on scrolling .

So there are only visible five, rows total table contol is not visible there .

Any idea for that ?

Thanks,

SS

Former Member
0 Kudos

Hi

I guess that's standard functionality in SRM. Which custom transaction are you

developing ? Give some details with code.

Also, Check it out, whether in the HTML template, there is some value hardcoded as well.

Hope this will help.

Please reward suitable points, incase it suits your requirements.

Regards

- Atul

Former Member
0 Kudos

Hi,

Is there any idea for this issue ?

Thanks,

SS

Former Member
0 Kudos

Hi,

ITS tableview and visible tablerow is related to ABAP screen.

For example: if you modify tableview in ABAP (expand the table layout to 10rows)

you will see 10 rows in ITS.

SAP uses links to next rows in ITS.

Regards,

Marcin

Former Member
0 Kudos

Hi Marcin ,

Can you send me details/code to handle the next row after the visible rows in SAP gui .I am getting visible rows + empty rows (Thsee upto whole data content of table control ) .

Thanks in advance .

Thanks,

SS

Former Member
0 Kudos

Hi,

Is there any idea for this ?

Thanks,

SS

Former Member
0 Kudos

Hi,

Sorry for my delay...

code at the end of table should end of problem.

Try it. This code counts row in table control and add button BBPTCNavigation for this.

If your table have 5 rows in ABAP screen and for example 11 elements inside, page navigation divide elements for five in a bag and writes something like that:

" << < 1 - 5 From 11 > >>"


      `if((TC_PERSONAREA.firstvisible > 1 ) || (TC_PERSONAREA.lastvisible < TC_PERSONAREA.rowcount))`
        <td  tabindex="0" align="right" valign="middle">
          `BBPTCNavigation("TC_PERSONAREA", emptyLinesGroup)`
        </td>
      `end`

Regards,

Marcin

Former Member
0 Kudos

Hi Marcin ,

Thanks for your response.

Actually the statement

if((TC_PERSONAREA.firstvisible > 1 ) || (TC_PERSONAREA.lastvisible < TC_PERSONAREA.rowcount))` is not working here .

Thanks,

SS

Former Member
0 Kudos

HI Marcin ,

Problem has been resolved ..

Thanks,

SS

Former Member
0 Kudos

Hi Marcin,

Browsing through the internet, I found only ur post helpful for putting up Table Control in ITS HTML templates.

My requirement is like :

in a bar code scanner, I have to provide a Table in edit mode, where a set of bar codes gets captured in each line item for a particular material (multiple barcodes for each material comprising different data viz. batch name, quantity, shelf life, etc).

while generating the template for the Table control screen, it gives a warning :

 

Element type TC_MAKT not supported. Element TABLE, screen:

ZDISCO_ITS_GRN_SCANNER 5006

     Message no. ITS_GENERATE_TEMPL106

any inputs ??

Answers (0)