Skip to Content

How do I include nested BSP element tags in a custom BSP element?


I'm trying to write a custom BSP tag that will enable me to write a single tag on my page to wrap the following sort of thing::

<thtmlb:gridCell columnIndex = "1"
                 rowIndex    = "<%= lv_row %>" >
  <thtmlb:label text   = "LABEL"
                for    = "TEXTVIEW_ID" />
<thtmlb:gridCell columnIndex = "2"
                 rowIndex    = "<%= lv_row %>" >
  <thtmlb:textView id     = "TEXTVIEW_ID"
                   text   = "//MODEL/VALUE" />

This will enable me to write something like this on the page:

<thtmlb:grid columnSize        = "2"
             rowSize           = "20" >
  <zbsp:formLabelValue valueId = "MT_TEXTVIEW1"
                       label   = "Label1"
                       value   = "//MODEL/VALUE1" />
  <zbsp:formLabelValue valueId = "MT_TEXTVIEW2"
                       label   = "Label2"
                       value   = "//MODEL/VALUE2" />

I've created my element and redefined the DO_AT_BEGINNING method. I've used the CL_THTMLB_GRIDCELL=>FACTORY method to create a gridcell and set its M_PARENT to be ME (i.e. my custom BSP tag). This allows the gridcell to be associated with the grid that it's in. I can then create a label using its factory method, but how can I put this label inside the gridCell? I've been mucking about with BSP writers and trying to debug what's happening, but I don't seem to be getting anywhere.

Has anyone written something like this in the past (embedded HTMLB elements within a custom BSP element) that I could look at?

Many thanks,


Add comment
10|10000 characters needed characters exceeded

1 Answer

  • Posted on Sep 21, 2010 at 04:21 PM

    Don't worry, I've worked it out!

    Add comment
    10|10000 characters needed characters exceeded